AbstractBioelectrochemical systems (BES) is a new and expanding technology that can simultaneously convert chemical energy into electrical energy by removing nutrients. The present study investigated the BES in removing nitrogen compounds and produce electricity. To this end, a BES reactor with two chambers of cathode and anode and nafion 117 membrane was used as a separator between the two chambers. Then, the BES performance at different concentrations of COD and primary ammonium at different retention times was investigated to remove nitrogen compounds and organic matter. Voltage, current and power density were measured. The results showed that the maximum COD removal efficiency was 73.2 % for the substrate concentration of 2000 mg/L, which decreased to 72.6 % when the substrate concentration increased to 10000 mg/L. The maximum removal efficiency of nitrogen compounds was 83.4 % at COD 10000 mg/L and the initial ammonium concentration was 50 mg/L. The maximum voltage, current and power density in this phase were 391 mV, 460 mA/m2, 63/48 mW/m2, respectively. The results of the study showed that BES can be used as a suitable method to remove high amounts of ammonium in wastewater and organic materials and simultaneously produce electricity.