Lightning also converts nitrogen gas to nitrate compounds. The Haber process converts nitrogen gas into ammonia used in fertilizers. Ammonia is converted to nitrates by nitrifying bacteria in the soil. Plants absorb nitrates from the soil and use these to build up proteins.