The two main gases found in Earth's atmosphere are nitrogen and oxygen. Nitrogen makes up 78 percent of the atmosphere, and oxygen makes up 21 percent. The remaining 1 percent consists of other gases, such as argon and water vapor.
Although the atmosphere is made up of four times as much nitrogen as oxygen, oxygen is the more abundant element on Earth. Nitrogen is more prevalent in the atmosphere because it is not as reactive as oxygen and has had a chance to build up.
The oxygen in the atmosphere mainly originated as a byproduct of photosynthesis. The process of photosynthesis is the means by which plants make their own food. They take in carbon dioxide and water in the presence of sunlight to produce glucose, water and oxygen.