The greenhouse effect itself occurs when short-wave solar radiation (which is not impeded by the greenhouse gases) heats the surface of the Earth, and the energy is radiated back through the Earth's atmosphere as heat, with a longer wavelength. In the wavelengths 5-30m a lot of this thermal radiation is absorbed by water vapour and carbon dioxide, which in turn radiate it, thus heating the atmosphere and land and ocean surface. This is natural and what keeps the Earth habitable.