Sunlight heats the Earth's surface but in the shade it stays cooler. At night the situation is reverse. Shaded areas remain warmer than those exposed to the sky. The surface cools at night because energy from sunlight is radiated out to space in the 10-micron (wavelength) region of the spectrum.