Those gas molecules in the Earth's atmosphere with three or more atoms are called "greenhouse gases" because they can capture outgoing infrared energy from the Earth, thereby warming the planet. The greenhouse gases include water vapor with three atoms (H2O), ozone (O3), carbon dioxide (CO2), and methane (CH4). Also, trace quantities of chloro-fluoro-carbons (CFC's) can have a disproportionately large effect.
Rainforests play a vital role in locking up the carbon in their vegetation via the process of photosynthesis. But when forests are burned, cleaned or degraded, large amounts of carbon are released into the atmosphere in the form of carbon dioxide and other greenhouse gases.
Carbon dioxide - Water Treatment and Purification - Lenntech
The fundamental reason why scientists are generally confident that we are and soon will be experiencing global warming is because the concentration of carbon dioxide (CO2) has been increasing steadily in the global atmosphere (Fig 1). Unlike water vapour or aerosol, CO2 is well-mixed in the atmosphere and changes are relatively slow. There is an annual cycle, evident in Fig 1 and explained in the book (Section 1.3), but its amplitude is small compared to the trend. (The annual cycle of water vapour concentration is much larger than any trend.) Carbon dioxide is a major greenhouse gas, and even the simplest one-dimensional radiative transfer model predicts surface warming when greenhouse-gas concentrations rise. Other factors affecting climate, such as the and indirect effect of aerosols, are much harder to measure, display large variability, and their effect on climate is poorly understood. It is because of these 'other factors' that scientists are not overly confident.