The growth of the environment depends upon developing greener and ecological methods for managing pollutants and contamination from industrial wastewater, which causes significant effects on human health. The removal of these pollutants from wastewater using nanomaterials covers an ecological method that is free from expensive and secondary pollution. In this report, we developed magnetic iron nanoparticles from Chenopodium glaucum (CG), which showed excellent adsorption capacity at pH 5 for selective Hg2+ and Pb2+ metal ions among various heavy metal ions, with maximum adsorption capacities of 96.9 and 94.1%, respectively. These metals' adsorption process conforms to the Langmuir model, which suggests that monolayer adsorption transpires on CG-Fe2O3 nanoparticles. CG-Fe2O3 nanoparticles also act as an efficient and recyclable heterogeneous catalyst for one-pot synthesis of xanthene derivatives, yielding products with high yields (up to 97%) and excellent purity (crystalline form) within a short timeframe (6 min) using microwave irradiations (at 120 W).