Over-application of nitrogen fertilizer induces soil acidification, which activates heavy metals availability and poses significant challenge to crop production and food safety. In this study, we prepared a clay-based material by ball-milling bentonite with NH4Cl (NH4Cl@bentonite) and assessed its synergistic performance in enhancing nitrogen fertilizer utilization efficiency, immobilizing heavy metals, and improving crop yield and safety. The results showed that the optimal performance of NH4Cl@bentonite was achieved by milling bentonite with NH4Cl at a 4:1 mass ratio for 9 h. NH4Cl@bentonite significantly improved soil water holding and retention capacity by 1.6 and 4.3 times, respectively. In comparison to NH4Cl alone, NH4Cl@bentonite led to a 22.3% increase in N-use efficiency and a 1.5 times enhancement in crop yield. The Pb and Cd content in water spinach shoots decreased by 55.3% and 57.5%, respectively, attributed to the transformation of heavy metals into lower bioavailability states by NH4Cl@bentonite. Experiments and Density Functional Theory (DFT) calculations indicated that NH4Cl@bentonite could immobilize Pb and Cd through processes such as cation exchange, surface adsorption, complexation, and enhancement of soil pH. This work proposes a simple and efficient method for improving cropland fertilizer utilization while ensuring healthy and sustainable development. Environmental implicationSoil acidification, caused using chemical fertilizers, especially nitrogen-based ones, threatens crop production and food safety by damaging soil structure, speeding up nutrient loss, and increasing the solubility of heavy metals. To tackle this problem, we made a clay material by mixing bentonite with NH4Cl (NH4Cl@bentonite) in a ball mill. NH4Cl@bentonite increased N-use efficiency by 22.3%, boosted crop yield by 1.5 times, and reduced the Pb and Cd levels in water spinach shoots by 55.3% and 57.5%, respectively. This work suggests a simple and effective way to enhance fertilizer use in croplands while ensuring healthy and sustainable development.