Coal is the dirtiest of fossil fuels—it produces per kilogram the least amount of energy and the greatest amount of pollution—and the world is quickly abandoning it.

According to findings published by the NGOs Greenpeace and CoalSwarm on Wednesday (Oct. 18), countries are using coal less and less to generate electricity, and hundreds of companies have exited the business in recent years.

“Of the 1,675 companies that have owned coal-fired power plants or pursued development of coal-fired power capacity since 2010, over a quarter (448 companies) have exited the coal power business entirely,” noted CoalSwarm.

Most of the departing companies came from the countries with the greatest amount of coal production and consumption. India, the world’s second-largest coal consumer last year, topped the list with the most departing companies, followed by China and the US, according to the NGOs.

The exodus has come amid a global clampdown on the industry, noted CoalSwarm. The world saw a 25% decline in investments for new coal-fired power plants last year, according to the International Energy Agency. Meanwhile the number of construction projects for new coal power plants dropped by two-thirds in the same period, according to a report in March co-authored by CoalSwarm, Greenpeace, and the Sierra Club.

For governments, there are many reasons to phase out coal production, among them overcapacity and air pollution. Some of India’s largest state-owned enterprises are reducing production due to tepid demand from thermal power plants. Coal India, which accounts for over 80% of the domestic output, in April lowered by 10% its production target for this year. And India has retired around 4 gigawatts of coal-fired power plants in the past two years.

China has also been aggressively downsizing the coal industry—including a halt of more than 150 coal-fired power plants with a combined operating capacity of Germany and Japan.

“Record amounts of coal-fired capacity were retired in the past two years,” said Christine Shearer, a senior researcher with CoalSwarm, in a press release. “And the growing number of phase-out policies means the trend will accelerate. Improving competitiveness of clean energy, poor economics of coal, air pollution problems and efforts to tackle climate change have all played a key role in accelerating the demise of coal.”

Still, the world is set to get more coal plants—largely a result of the time lag for big infrastructure projects, which require approval years before construction begins. That’s the case with China, which has six of the world’s top 10 companies ranked by the number of its proposed coal plants. Together, these 10 firms will have 130 GW of power capacity—10% of the globe’s total, data from CoalSwarm showed.