Nitrogen cycle
The nitrogen cycle is the biogeochemical cycle that describes the transformations of nitrogen and nitrogen-containing compounds in nature.
Earth's atmosphere is about 78% nitrogen, making it the largest pool of nitrogen. Nitrogen is essential for many biological processes; and is crucial for any life here on Earth. It is in all amino acids, is incorporated into proteins, and is present in the bases that make up nucleic acids, such as DNA and RNA. In plants, much of the nitrogen is used in chlorophyll molecules which are essential for photosynthesis and further growth.
Processing, or fixation, is necessary to convert gaseous nitrogen into forms usable by living organisms. Some fixation occurs in lightning strikes, but most fixation is done by free-living or symbiotic bacteria. These bacteria have the nitrogenase enzyme that combines gaseous nitrogen with hydrogen to produce ammonia, which is then further converted by the bacteria to make its own organic compounds. Some nitrogen fixing bacteria, such as Rhizobium, live in the root nodules of legumes (such as peas or beans). Here they form a mutualistic relationship with the plant, producing ammonia in exchange for carbohydrates. Nutrient-poor soils can be planted with legumes to enrich them with nitrogen. A few other plants can form such symbioses.
Other plants get nitrogen from the soil by absorption at their roots in the form of either nitrate ions or ammonium ions. All nitrogen obtained by animals can be traced back to the eating of plants at some stage of the food chain.

# Ammonia
The source of ammonia is the decomposition of dead organic matter by bacteria called decomposers, which produce ammonium ions (NH4). In well-oxygenated soil, these ions are then oxygenated first by nitrifying bacteria into nitrite (NO2-) and then into nitrate (NO3-). This two-step conversion of ammonium into nitrate is called nitrification.
Ammonium ions readily bind to soils, especially to humic substances and clays. Nitrate and nitrite ions, due to their negative electric charge, bind less readily since there are less positively charged ion-exchange sites (mostly humic substances) in soil than negative. After rain or irrigation, leaching (the removal of soluble ions, such as nitrate and nitrite) into groundwater can occur. Elevated nitrate in groundwater is a concern for drinking water use because nitrate can interfere with blood-oxygen levels in infants and cause methemoglobinemia or blue-baby syndrome. Where groundwater recharges stream flow, nitrate-enriched groundwater can contribute to eutrophication, a process leading to high algal, especially blue-green algal populations and the death of aquatic life due to excessive demand for oxygen. While not directly toxic to fish life like ammonia, nitrate can have indirect effects on fish if it contributes to this eutrophication. Nitrogen has contributed to severe eutrophication problems in some water bodies. As of 2006, the application of nitrogen fertilizer is being increasingly controlled in Britain and the United States. This is occurring along the same lines as control of phosphorus fertilizer, restriction of which is normally considered essential to the recovery of eutrophied waterbodies.
Ammonia is highly toxic to fish life and the water discharge level of ammonia from wastewater treatment plants must often be closely monitored. To prevent loss of fish, nitrification prior to discharge is often desirable. Land application can be an attractive alternative to the mechanical aeration needed for nitrification.
During anaerobic (low oxygen) conditions, denitrification by bacteria occurs. This results in nitrates being converted to nitrogen gas and returned to the atmosphere. Nitrate can also be reduced to nitrite and subsequently combine with ammonium in the anammox process, which also results in the production of dinitrogen gas.

# Processes of the nitrogen cycle

## Nitrogen fixation

### Conversion of N2
The conversion of dinitrogen (N2) from the atmosphere into a form readily available to plants and hence to animals and humans is an important step in the  nitrogen cycle, that determines the supply of this essential nutrient. There are four ways to convert N2 (atmospheric nitrogen gas) into more chemically reactive forms:
- Biological fixation: some symbiotic bacteria (most often associated with leguminous plants) and some free-living bacteria are able to fix nitrogen and assimilate it as organic nitrogen. An example of mutualistic nitrogen fixing bacteria are the Rhizobium bacteria, which live in legume root nodules. These species are diazotrophs. An example of the free-living bacteria is Azotobacter.
- Industrial N-fixation : in the Haber-Bosch process, N2 is converted together with hydrogen gas (H2) into ammonia (NH3) fertilizer and explosives.
- Combustion of fossil fuels : automobile engines and thermal power plants, which release NOx.
- Other processes : Additionally, the formation of NO from N2 and O2 due to photons and especially lightning, are important for atmospheric chemistry, but not for terrestrial or aquatic nitrogen turnover.

## Assimilation
Plants can absorb nitrate or ammonium ions from the soil via their root hairs. If nitrate is absorbed, it is first reduced to nitrite ions and then ammonium ions for incorporation into amino acids, nucleic acids, and chlorophyll. In plants which have a mutualistic relationship with rhizobia, some nitrogen is assimilated in the form of ammonium ions directly from the nodules. Animals, fungi, and other heterotrophic organisms absorb nitrogen as amino acids, nucleotides and other small organic molecules.

## Ammonification
When a plant or animal dies, or an animal excretes, the initial form of nitrogen is organic. Bacteria, or in some cases, fungi, convert the organic nitrogen within the remains back into ammonia, a process called ammonification or mineralization.

## Nitrification
The conversion of ammonia to nitrates is performed primarily by soil-living bacteria and other nitrifying bacteria. The primary stage of nitrification, the oxidation of ammonia (NH3) is performed by bacteria such as the Nitrosomonas species, which converts ammonia to nitrites (NO2-). Other bacterial species, such as the Nitrobacter, are responsible for the oxidation of the nitrites into nitrates (NO3-).

## Denitrification
Denitrification is the reduction of nitrites back into the largely inert nitrogen gas (N2), completing the nitrogen cycle. This process is performed by bacterial species such as the Pseudomonas and Clostridium in anaerobic conditions. They use the nitrate as an electron acceptor in the place of oxygen during respiration. These facultatively anaerobic bacteria can also live in aerobic conditions.

## Anaerobic ammonium oxidation
In this biological process, nitrite and ammonium are converted directly into dinitrogen gas. This process makes up a major proportion of dinitrogen conversion in the oceans.

# Human influences on the nitrogen cycle
As a result of extensive cultivation of legumes (particularly soy, alfalfa, and clover), growing use of the Haber-Bosch process in the creation of chemical fertilizers, and pollution emitted by vehicles and industrial plants, human beings have more than doubled the annual transfer of nitrogen into biologically available forms. In addition, humans have significantly contributed to the transfer of nitrogen trace gases from Earth to the atmosphere, and from the land to aquatic systems.
N2O has risen in the atmosphere as a result of agricultural fertilization, biomass burning, cattle and feedlots, and other industrial sources. N2O has deleterious effects in the stratosphere, where it breaks down and acts as a catalyst in the destruction of atmospheric ozone. Ammonia (NH3) in the atmosphere has tripled as the result of human activities. It is a reactant in the atmosphere, where it acts as an aerosol, decreasing air quality and clinging on to water droplets, eventually resulting in acid rain. Fossil fuel combustion has contributed to a 6 or 7 fold increase in NOx flux to the atmosphere. NOx actively alters atmospheric chemistry, and is a precursor of tropospheric (lower atmosphere) ozone production, which contributes to smog, acid rain, and increases nitrogen inputs to ecosystems. Ecosystem processes can increase with nitrogen fertilization, but anthropogenic input can also result in nitrogen saturation, which weakens productivity and can kill plants. Decreases in biodiversity can also result if higher nitrogen availability increases nitrogen-demanding grasses, causing a degradation of nitrogen-poor, species diverse heathlands.

## Wastewater
Onsite sewage facilities such as septic tanks and holding tanks release large amounts of nitrogen into the environment by discharging through a drainfield into the ground. Microbial activity consumes the nitrogen and other contaminants in the wastewater. However, in certain areas the soil is unsuitable to handle some or all of the wastewater, and as a result, the wastewater with the contaminants enters the aquifers. These contaminants accumulate and eventually end up in drinking water. One of the contaminants concerned about the most is nitrogen in the form of nitrates. A nitrate concentration of 10 ppm or 10 milligrams per liter is the current EPA limit for drinking water and typical household wastewater can produce a range of 20-85 ppm (milligrams per liter).
The health risk associated with drinking >10 ppm nitrogen water is the development of methemoglobinemia and has been found to cause blue baby syndrome. Several states have now started programs to introduce advanced wastewater treatment systems to the typical onsite sewage facilities. The result of these systems is an overall reduction of nitrogen, as well as other contaminants in the wastewater.