The nations of the world are on the verge of reaching a new deal to fight climate change — while also protecting the ozone layer.

Talks in Vienna, Austria, have been leading toward a worldwide agreement to phase out the use of hydrofluorocarbons (HFCs). They were widely adopted to replace chlorofluorocarbons (CFCs) in air conditioners and refrigerators after it was discovered that CFCs were creating a hole in the ozone layer. The Montreal Protocol, a landmark treaty, phased CFCs out. But while HFCs don’t damage the ozone layer, it turns out they are potent greenhouses gases, trapping thousands of times more heat than carbon dioxide, so now they need to go too. Researchers think that by cutting HFCs globally, we could prevent up to 0.5 degrees C of global warming by 2100.

Help Grist raise $25,000 by September 30 to further advance our climate reporting

Negotiators are currently working on adding an HFC-cutting amendment to the Montreal Protocol, which would be the single largest measure to fight climate change since the Paris Agreement was reached last December. Under the current draft of the amendment, developed nations like the United States would eliminate HFCs by the 2030s, while developing nations would have until the 2040s. Developed nations would also help pay for the transition. The deal could be finalized in Rwanda in October.

U.S. Secretary of State John Kerry, who’s been playing a key role in the negotiations, says, “an HFC phase-down amendment is a critical piece of the climate puzzle.”