CHINA dominates international trade in many goods, but few more than waste for recycling. It sucked in more than half the world’s exports of scrap copper and waste paper in 2016, and half of its used plastic. All in all, China spent over $18bn on imports of rubbish last year. America, meanwhile, is an eager supplier. In 2016 nearly a quarter of America’s biggest exporters by volume were recyclers of paper, plastic or metal. Topping the list was America Chung Nam, a California-based supplier of waste paper which last year exported a whopping 333,900 containers, almost all of them to China.

This may soon change. On July 18th China told the World Trade Organisation that by the end of the year, it will no longer accept imports of 24 categories of solid waste as part of a government campaign against yang laji or “foreign garbage”. The Ministry of Environmental Protection says restricting such imports will protect the environment and improve public health. But the proposed import ban will disrupt billions of dollars in trade. Recyclers worry that other categories of waste may soon receive the same treatment.

Imports of rubbish have helped feed China’s voracious appetite for raw materials. It is often cheaper to recycle scrap copper, iron and steel, as well as waste paper and plastic, than to make such materials from scratch, especially when commodity prices are high. So as commodity prices rose during the 2000s, the burgeoning trade in waste benefited both exporters, who made money from previously worthless trash, and importers, who gained access to a reliable stream of precious feedstock. Between 1995 and 2016 Chinese imports of waste grew tenfold, from 4.5m to 45m tonnes.

But imports of recyclable waste are often dirty, poorly sorted or contaminated with hazardous substances such as lead or mercury. In 1996 factories in Xinjiang inadvertently imported more than 100 tonnes of radioactive metal from Kazakhstan. The following year an American businessman was convicted of smuggling over 200 tonnes of unsorted rubbish labelled as waste paper. Even when the intended material is imported, it is often recycled improperly. In 2002 the authorities faced widespread criticism after a documentary showed workers in Guangdong province crudely dismantling discarded electronic devices and dumping the toxic remains into a river. Officials may have been spurred into the latest restrictions by the release of Plastic China, an unflattering documentary about the plastic-recycling industry which was screened at Sundance, a grand American film festival, in January.

The government had already been campaigning to block imports of illegal and low-quality waste under a crackdown called Operation Green Fence launched in 2013. Customs officials have ramped up inspections of scrap metal for circuit boards, plastic for syringes and other medical waste, and waste paper for plastic or wood. Since then, China’s imports of waste have fallen sharply (see chart).