Last Friday, Oregon became the first state to ban coal outright, passing a bill that will phase out any electricity generated by coal by 2035. Several days earlier, the U.S. Energy Information Administration (EIA) reported that 80 percent of last year’s retired electricity was coal-powered. In 2016, natural gas is expected to produce 33.4 percent of electricity versus coal’s 32 percent. At a time when the coal industry is facing one setback after another, it prompts the question: Has the “war on coal” been won?

The case of Oregon is a unique one. In a green-minded, true-blue state, where spending time among the Douglas firs is a cultural requisite, it’s not entirely surprising that coal is no longer welcome, even if coal currently makes up over 30 percent of the state’s power. Whether Oregon’s approach will be adopted by other states is far from clear, especially since over half the country’s states are challenging President Barack Obama’s Clean Power Plan, which contains new rules that are designed to encourage the use of renewable energy and natural gas at the expense of coal.

But Mary Anne Hitt, director of Sierra Club’s Beyond Coal campaign, says state challenges to the Environmental Protection Agency’s regulations can’t stop a sea change in how we get our energy. “Momentum, in my view, has been driven more by state and local advocacy and leadership,” she said. “The long-term trajectory for the coal industry is the United States is moving away from coal. It’s politically expedient, especially for Republicans, to point the finger at President Obama—but the real power behind this transition came from the American people and it came up from the grassroots.” 

Whether coal’s fall will be swift or slow will depend on Obama’s successor. But due to a confluence of economic and political factors—as well as international pressure stemming from the Paris climate change agreement—even a Republican president can’t prop up the industry for long.

Much of this is Obama’s doing. During his two terms, regulations limiting carbon output and mercury emissions has cost companies. Since Obama took office, some coal company shares have tumbled 90 percent, with coal production falling by 15 percent and wind and solar power increasing by over 200 percent. A handful of the country’s largest coal companies have declared bankruptcy in the past two years, with another likely on its way this month. On Thursday, his administration offered $65.8 million for job training and other development in communities traditionally reliant on the coal economy.

But Obama’s impact on the coal industry has been assisted by the fact that natural gas is cheap and plentiful. EIA predicts U.S. coal production will decrease by another 12 percent this year, the greatest annual percentage decline since 1958. As Hitt puts it, “It’s the way the world is moving.”

And professional environmentalists aren’t the only ones who think so. “Utilities are really coming to grips with how they need to adapt to a changing climate,” said Dave Robertson of Portland General Electric, one of two utilities that serve 70 percent of customers in Oregon, and a collaborator on the Oregon legislation. He said that over the next 25 years “we’re going to need to have new power plants anyways.”

Whether those plants will continue to burn coal is up to utilities and power producers. And recently, companies have been deciding against it. According to the magazine Pacific Standard, of the 523 coal plants in operation over the last five years, more than 200 have closed or soon will. Furthermore, no new coal plants are currently planned in the United States. 

“To me saying this is a war on coal is saying the Internet is a war on typewriters,” said Bob Keefe, executive director for E2, a partner of the Natural Resources Defense Council. “The fact of the matter is that the energy business … is in transition. The good news is that like any major industry transition, we’re seeing a lot of progress”—specifically, the addition of 250,000 clean energy jobs in the last four years.

Renewable energy is also getting cheaper, leading to an expected 8 percent increase in renewables this year. “The ‘war on coal’ is being driven by lots of different dynamics including a huge drop in the cost of renewables and then obviously to an extent the drop in price in natural gas in the United States,” said Jake Schmidt of the NRDC. It has become economically rational “to shift away from coal to one of these sources and a lot of companies are choosing natural gas.” 

To keep that edge, Keefe says the Clean Power Plan will have to move forward. Obama’s decision this week to limit methane leaks on existing oil and gas wells will also be key. For natural gas to provide a bridge to renewables, drilling practices will have to be regulated and standardized to avoid flack from critics who say natural gas is nearly as destructive to the environment as traditional sources of energy.

In the presidential election, the candidates’ stances on coal and diversifying energy have been important on both sides of the race. Bernie Sanders has been able to maintain his anti-coal stance while drawing support from coal country. Hillary Clinton, for her part, has had a tougher time. This week, the Democratic frontrunner said she’s going to “put a lot of coal companies and coal miners out of business.” In the same breath, she clarified that she wanted to buoy coal miners who have worked to power the country. Still, Republicans like Mitch McConnell seized on the comments, calling them “callous.” Politicians in coal-dependent West Virginia were appalled. Clinton walked back her comments, saying, “Coal will remain a part of the energy mix for years to come.” Days later, she was able to pull out a victory in Ohio coal country.

Republicans coined the phrase “war on coal” as a pejorative way to describe Obama’s regulatory policies. This year’s presidential race has continued that belligerently pro-coal approach. Trump has been particularly outspoken, calling Obama’s war a job killer, and he has raked in coal country votes and support for his efforts. 

But according to Keefe, rhetorical assaults designed to boost coal are a waste of time. “If I’m a coal state politician, instead of harping about some other party’s ‘war on coal’ I would be trying my best to help those workers,” he said. “Getting them some worker retraining programs and more importantly getting more clean energy … in my state.” Clearing the way for budding renewables programs will help to ease the absence of coal across the country. Nevada has faced what Keefe calls a “solar debacle,” thanks to regulators dumping extra electricity costs on solar users, and North Carolina and Florida have seen similar struggles. Sorting out these regulations will take some pressure off natural gas.

International markets are also catching on. Though coal is still the world’s largest fuel source, 2014 showed the first decline in its consumption since the 1990s. The International Energy Agency expects consumption growth to continue, but it will be more measured.

In 2013, China became the largest coal importer and the country accounts for half of the world’s consumption. But in the last two years, its coal consumption has fallen, and its latest Five Year Plan set an energy consumption cap—part of what Schmidt describes as the country’s “war on pollution.” A recent study suggests the country’s carbon emissions may have already peaked. “At the same time, China has been basically building out a renewable-energy, clean-energy economy at a scale larger than all of the other countries in the world have done,” Schmidt explains. “When you look around the world and give it an honest assessment, you see coal consumption on decline. There’s just no way you can have China’s numbers dropping and not have it have a ripple effect.”

Though India is still building coal plants, it’s another bright spot on the renewables map, with solar challenging traditional carbon sources. China has already overtaken Germany to become the country with the largest installed solar capacity. 

In the short term, Clinton is correct—coal will remain part of the energy mix in both the U.S. and around the world. But market trends imply that won’t be the case for much longer, even if a President Trump does everything in his power to prop up Big Coal.