Nitrogen fixation, the biological reduction of dinitrogen gas (N2) to ammonium (NH4+), is quantitatively the most important external source of new nitrogen (N) to the open ocean. Classically, the ecological niche of oceanic N2 fixers (diazotrophs) is ascribed to tropical oligotrophic surface waters, often depleted in fixed N, with a diazotrophic community dominated by cyanobacteria. Although this applies for large areas of the ocean, biogeochemical models and phylogenetic studies suggest that the oceanic diazotrophic niche may be much broader than previously considered, resulting in major implications for the global N-budget. Here, we report on the composition, distribution and abundance of nifH, the functional gene marker for N2 fixation. Our results show the presence of eight clades of diazotrophs in the oxygen minimum zone (OMZ) off Peru. Although proteobacterial clades dominated overall, two clusters affiliated to spirochaeta and archaea were identified. N2 fixation was detected within OMZ waters and was stimulated by the addition of organic carbon sources supporting the view that non-phototrophic diazotrophs were actively fixing dinitrogen. The observed co-occurrence of key functional genes for N2 fixation, nitrification, anammox and denitrification suggests that a close spatial coupling of N-input and N-loss processes exists in the OMZ off Peru. The wide distribution of diazotrophs throughout the water column adds to the emerging view that the habitat of marine diazotrophs can be extended to low oxygen/high nitrate areas. Furthermore, our statistical analysis suggests that NO2- and PO43- are the major factors affecting diazotrophic distribution throughout the OMZ. In view of the predicted increase in ocean deoxygenation resulting from global warming, our findings indicate that the importance of OMZs as niches for N2 fixation may increase in the futur