Question:How does the Greenhouse Effect work?
It all has to do with Infrared radiation.
Most of the heat on Earth comes from the Sun. Heat from the Sun is transferred to the Earth by means of radiation.
The Sun is very hot. So the infrared radiation from the Sun is close to the visible light end of the infrared spectrum. This means the infrared electromagnetic waves from the Sun have high energy and frequency but short wavelengths.
The Earth is much cooler than the Sun, but the surface of the Earth still emits infrared radiation which is how the surface of the Earth cools down at night when the Sun is not replacing the heat radiating away from the Earth's surface as it does during the day. The infrared waves from the earth have lower energy and frequency and much longer wavelengths than those from the Sun because they are being emitted by a cooler object.
It turns out that the different types of infrared waves (we will focus just on wavelength now) behave differently when they encounter the gases in the Earth's atmosphere.
The shorter wavelength waves from the Sun pass straight through and are absorbed by the Surface of the Earth, warming the Earth up. But the longer wavelength waves emitted by the Earth are partly absorbed by some of the gases in the atmosphere, preventing the loss of the heat energy the infrared waves contain from the atmosphere.
It is called the greenhouse effect because the inside of a greenhouse remains warm for the same reason. Infrared from the Sun goes straight through the glass, but the infrared emitted by the contents of the greenhouse are reflected back inside by the glass, reducing the rate of heat loss.