The sun s energy passes through the vapor-laden atmosphere largely undiminished until it hits the land or sea and is converted to heat energy. Earth s surface radiates that energy skyward again as infrared radiation. Water vapor is not transparent to infrared. The water molecules in the atmosphere absorb the infrared energy and become hotter. So the radiant heat energy in the infrared rays is temporarily captured in the atmosphere.
Water vapor is responsible for about two-thirds of the natural greenhouse effect.
There s an important difference between water vapor and other greenhouse gases. Human activities do not seem to be appreciably changing the atmospheric concentration of water vapor in any direct way on the global average. Nor does water vapor accumulate in the atmosphere over the multi-year periods that other greenhouse gases do. Water stays in the atmosphere for a few days, while other greenhouse gases linger for decades or centuries. But humans may be increasing water vapor indirectly.