Is it possible to create conditions in the anaerobic digesters to control nutrients without changing the performance of a reactor? This study investigates an answer for this question. To this purpose, anaerobic reactors are operated at high concentrations of Mg2+ ion to harvest the nutrient ions (NH4 (+) and PO4 (3-)) in the form of struvite, that is, magnesium ammonium phosphate. The effects of this modification on the anaerobic digestion of sewage sludge were investigated in terms of chemical oxygen demand (COD) removal and cumulative CH4 production as well as the changes in the biological diversity. The results showed that approximately 50 % of the nutrients (NH4 (+) and PO4 (3-)) were removed regardless of the method adopted for the addition of Mg2+ ion, slug or daily dosing. The numbers of Methanosaeta and Methanosarcina in the samples withdrawn prior to and after the addition of Mg2+ did not show significant difference according to the results obtained from qPCR analyses. The research results showed that the addition of Mg2+ into the anaerobic digesters in municipal wastewater treatment facilities may help to remove the nutrients from the effluent while recovering in their solid forms.