Answer :
nitrogen fixing bacteria in soil converts nitrogen gas in the atmosphere to ammonia, then nitrifying bacteria convert ammonia to nitrates or nitrites. Then ammonia, nitrates and nitrites are all fixed nitrogen which can then be absorbed by plants :)