The troposphere is the lowest layer of Earth's atmosphere, extending from the surface up to an average altitude of about 8 to 15 kilometers (5 to 9 miles). It is where most weather phenomena occur, including clouds, precipitation, and winds. The temperature in the troposphere generally decreases with altitude, due to the fact that it is heated from the Earth's surface. The troposphere is also where most of the Earth's atmospheric gases are found, including oxygen, nitrogen, and carbon dioxide.