If major global cities repurposed human waste as crop fertilizer, it could slash fertilizer imports in some countries by more than half. This discovery, outlined in a recent paper from Nature Sustainability, highlights the potential of human waste to reduce the vast environmental impact of fertilizer–and simultaneously help cities to manage their burgeoning waste.

Human feces and urine may be waste products, but they still contain many valuable nutrients like nitrogen, phosphorus and potassium that can be hygienically extracted and applied to crops. Looking at 56 global cities spread across six continents, the study researchers set out to determine whether human waste from these urban hubs could produce enough nutrients to feed agricultural land on city outskirts. This revealed global hotspots where this form of recycling could make a huge impact.

For instance, in the Egyptian city of Cairo, enough nutrients could be recovered from its human effluent to reduce Egypt’s potassium imports–a key ingredient in many fertilizers–by up to 70%. Between 2000 and 2010, Cairo also produced enough human waste to replace all phosphorus imports into the country, the researchers calculated. They also found that cities in Japan could harvest enough nutrients to replace 72% of the country’s nitrogen fertilizer imports, and in Buenos Aires nutrient extraction could offset 25% of Argentina’s potassium imports. In Khartoum, repurposed human waste would replace 73% of the potassium fertilizer that Sudan imports to feed its crops.

These astounding figures weren’t evident in all city contexts, however. The researchers found that in regions like Africa, Asia, and Europe where it’s common for high-density cities to be in close proximity to cropland, nutrients could be most efficiently redistributed to farmland. But in other parts of the world like the United States, big urban centres such as New York City and Boston are often too far from agricultural areas to make the transport of urban nutrients economically viable–especially if it takes the form of treated wastewater which would be heavy and therefore costly to transport. In these places, extracting crystallised nutrients from human effluent could be a cheaper way of getting this valuable resource to surrounding agricultural lands, the researchers note.

In cities where it is feasible, recycling human waste could bring major environmental benefits. By replacing large quantities of synthetic fertilizer, it would cut the greenhouse gas emissions that result from fertilizer production and transport. It would also help to control the water and soil pollution that often results from runoff of human effluent. And, relying on a localised supply of fertilizer could boost food security in some countries: If cities become reliable hubs of nutrient production, this would insulate local farmers–especially small scale subsistence farmers who are already vulnerable–from the fluctuating costs of fertilizer imports, and so safeguard their yields.

Of course, there is a hurdle: the notion of human-waste-fed crops isn’t going to be an easy sell for most people. But that belies the fact that we’ve actually been repurposing human waste as fertilizer for centuries. And, now that we’re developing ever-more sophisticated ways to make this process safe, it presents real potential to solve some of the biggest sustainability challenges at the nexus of consumption, production, and waste.

“We grow our crops in the field, apply nutrient-rich fertilizers, eat the crops, excrete all of the nitrogen, phosphorus and potassium and then those nutrients end up at the wastewater treatment plant,” the researchers say. “Engineering a more circular nutrient cycle would create opportunities that could benefit the environment, economy and agriculture.”