SAN FRANCISCO (AP) — A $100 million project removing dams and helping fish route around others is returning a badly endangered salmon to spring-fed waters in northernmost California, giving cold-loving native fish a life-saving place to chill as scientists say climate change, drought and human diversions warm the waters.

State and federal officials, in a years-long project with dam-owner Pacific Gas & Electric Co., plan to release 200,000 young, endangered winter-run Chinook salmon over the next two months into the north fork of Battle Creek, where melted snow percolating through volcanic rock provides ideal habitat for native salmon and steelhead that thrive in cold mountain water.

Dam-building for electrical generation and water storage from the 1930s blocked winter-run Chinook from upstream waterways, cutting their numbers from nearly a million to a few thousand barely getting by in warm downstream stretches of the Sacramento River, the state Department of Fish and Wildlife says.

The National Oceanic and Atmospheric Administration ranks winter-run Chinook as one of eight marine species most at risk of extinction.

Because of Battle Creek’s spring-fed cold water, and the difficulty of keeping the Sacramento River cool enough for the winter-run Chinook, state and federal agencies made a priority of making Battle Creek accessible to winter-run Chinook again.

“Battle Creek has long been recognized as an ideal resource for cold water from snow melt,” said Doug Killam, a senior environmental scientist with the state wildlife agency. “It’s kind of a jewel of the system.”

The ongoing restoration project has removed one dam blocking access to the fish and will remove four more dams. A similar agreement, now awaiting approval or denial by the Federal Energy Regulatory Commission, would remove a series of dams blocking access to salmon farther north, in the Klamath River watershed.

Other parts of this project included building better fish ladders and fish screens to give migrating salmon an easier time navigating around remaining obstacles.

It’s crucial to the survival of winter-run salmon to restore populations beyond the one hanging on in the Sacramento River, where a disaster like a chemical spill or another drought could wipe out the species, wildlife officials said.

In 2014 and 2015, nearly entire generations of the winter-run Chinook died in the too-warm Sacramento, as humans competed with the fish for water releases from behind Shasta Dam during a five-year drought.

Trying to keep cold-loving salmon by eeking out cold water from behind dams is becoming more complicated still as the climate changes, said Howard Brown of NOAA fisheries.

Man-made climate change is reducing the snow runoff that Californians — both animal and human — historically have depended upon for much of their water supply, scientists say.

Easing the winter-run Chinook’s dependence on a single waterway, the Sacramento, is a good start, a fishing industry trade group said in a statement.

“Salmon fishermen used to have good fishing right outside the Golden Gate in February years ago before winter run salmon were decimated,” said John McManus, head of the Golden Gate Salmon Association. “Maybe someday we’ll see this again.”