Mexico City is less than two hours away, so an overnight stay won't be necessary (the exception is Cuetzalan, which is six hours from the capital or four hours from Puebla). If you're going to Cuernavaca or Valle de Bravo, you should plan to overnight. Two nights in either city would allow you to do a side trip to the ruins of Xochicalco (from Cuernavaca) or to the Parque Nacional Nevado de Toluca (from Valle). You can visit Puebla on a day trip, but it would be a shame to rush it. Moreover, the city is lovely at night, when the buildings around the zócalo are floodlit, and the sidewalk cafés along the plaza fill up. If you do overnight, spend the first day seeing the city and the next day in nearby Cholula or at the ruins of Cacaxtla. In addition, you might want to leave some flexibility in your schedule for an overnight stay at the magical Hotel La Escondida in Tlaxcala.