|A hazy sun|
Since the solar system's beginning, the sun has increased its energy output by about 25 percent. What has that meant for earth? From ancient rocks, we can tell that a younger earth had surface liquid which can be taken to mean that earth has remained roughly the same temperature as we still have liquid water. If the sun was cooler back then, why wasn't the earth cooler? This is known as the 'faint young sun paradox'. A number of mechanisms may have been responsible for keeping a relatively constant surface temperature. Probably a combination of things are involved, but no one knows for sure. Here are some possibilities:
The Earth was warmer despite less incoming solar energy because of a larger greenhouse effect. For this to work, the greenhouse effect responsible would have tapered off as the sun grew brighter. The greenhouse effect is caused by an atmosphere rich in 'stuff' that prevents radiation from escaping. Two of the better culprits are water vapour and carbon dioxide (methane is a good at this too, as is nitrous oxide i.e., laughing gas). Assuming carbon dioxide played a big role, where would extra carbon dioxide come from? Way back, a more geologically active earth spewed more carbon dioxide from volcanoes. This excess carbon dioxide eventually was sunk into places like our oceans thereby reducing this greenhouse gas over time (only in the last 200 years have people begun spewing out our own contribution of this gas). So, when the sun was cooler the extra carbon dioxide created a greenhouse effect that has decreased at a similar rate as the sun heating up. Other processes probably put more of the other greenhouse gases into our atmosphere long ago and removed them slowly over time as well.
A recent thought based on big assumptions is that the early atmosphere also had more nitrogen. Nitrogen all on its own isn't a greenhouse gas on Earth (on Saturn's moon Titan, some funky stuff happens to the nitrogen, so there it acts a greenhouse gas), however extra nitrogen bounces around and hits the greenhouse gases which gives the greenhouse gases extra energy and makes them unstable or wobbly. This molecular wobble spreads out absorption lines (the range where a particular molecule absorbs energy) resulting in a wider band to absorb the radiation – thus more radiation is absorbed. On the flip side, extra nitrogen could also increase Rayleigh scattering, thus reflecting more of the incoming radiation away. So knowing which process dominated would be important.
As for why early earth wasn't colder with a cooler sun, we have good some ideas, but we really don't know for sure.
Walker, C.G., P.B. Hays and J.F. Kasting, 1981: A negative feedback mechanism for the long-term stabilization of Earth's surface temperature. Journal of Geophysical Research, 86, 9776-9782
Goldblatt, C., M.W. Claire, T.M. Lenton, A.J. Matthews, A.J. Watson and K.J. Zahnle, 2009: Nitrogen-enhanced greenhouse warming on early Earth. Nature Geoscience, 2, 891-896.