Ammonia (NH3) is an important industrial chemical that is produced using the energy- and carbon-intensive Haber-Bosch process. Recovering NH3 from microorganisms that fix nitrogen gas (N2) may provide a sustainable alternative because their specialized nitrogenase enzymes can reduce N2 to ammonium (NH4+) without the need for high temperature and pressure. This study explored the possibility of converting N2 into NH4+ using anaerobic, single-chamber microbial electrolysis cells (MECs). N2 fixation rates [based on an acetylene gas (C2H2) to ethylene gas (C2H4) conversion assay] of a microbial consortium increased significantly when the applied voltage between the anode and cathode increased from 0.7 to 1.0 V and reached a maximum of ∼40 nmol of C2H4 min–1 mg protein–1, which is comparable to model aerobic N2-fixing bacteria. The presence of NH4+, which can inhibit the activity of the nitrogenase enzyme, did not significantly reduce N2 fixation rates. Upon addition of methionine sulfoximine, an NH4+ uptake inhibitor, NH4+ was recovered at rates approaching 5.2 × 10–12 mol of NH4+ s–1 cm–2 (normalized to the anode surface area). Relative to the electrical energy consumed, the normalized energy demand [MJ mol–1 (NH4+)] was negative because of the energy-rich methane gas recovered in the MEC. Including the substrate energy resulted in total energy demands as low as 24 MJ mol–1. Community analysis results of the anode biofilms revealed that Geobacter species predominated in both the presence and absence of NH4+, suggesting that they played a key role in current generation and N2 fixation. This study shows that MECs may provide a new route for generating NH4+.