A group of young people in Montana won a landmark lawsuit on Monday when a judge ruled that the state’s failure to consider climate change when approving fossil fuel projects was unconstitutional.

The decision in the suit, Held v. Montana, coming during a summer of record heat and deadly wildfires, marks a victory in the expanding fight against government support for oil, gas and coal, the burning of which has rapidly warmed the planet.

“As fires rage in the West, fueled by fossil fuel pollution, today’s ruling in Montana is a game-changer that marks a turning point in this generation’s efforts to save the planet from the devastating effects of human-caused climate chaos,” said Julia Olson, the founder of Our Children’s Trust, a legal nonprofit group that brought the case on behalf of the young people. “This is a huge win for Montana, for youth, for democracy, and for our climate. More rulings like this will certainly come.”

The ruling means that Montana, a major coal and gas producing state that gets one-third of its energy by burning coal, must consider climate change when deciding whether to approve or renew fossil fuel projects.

The Montana attorney general’s office said the state would appeal, which would send the case to the state Supreme Court.

“This ruling is absurd, but not surprising from a judge who let the plaintiffs’ attorneys put on a weeklong taxpayer-funded publicity stunt that was supposed to be a trial,” Emily Flower, a spokeswoman for the attorney general, Austin Knudsen, said in a statement. “Montanans can’t be blamed for changing the climate.”

The case is part of a wave of litigation related to climate change that is targeting companies and governments around the globe. States and cities are suing companies like Exxon, Chevron and Shell, seeking damages from climate disasters and claiming that the companies have known for decades that their products were responsible for global warming. And individuals are now suing state and federal governments, claiming that they have enabled the fossil fuel industry and failed to protect their citizenry.

Michael Burger, executive director of the Sabin Center for Climate Change Litigation at Columbia University, said the Montana case would reverberate around the country.

“This was climate science on trial, and what the court has found as a matter of fact is that the science is right,” Mr. Burger said. “Emissions contribute to climate change, climate harms are real, people can experience climate harms individually, and every ton of greenhouse gas emissions matters. These are important factual findings, and other courts in the U.S. and around the world will look to this decision.”

The Montana case revolved around language in the state Constitution that guarantees residents “the right to a clean and healthful environment,” and stipulates that the state and individuals are responsible for maintaining and improving the environment “for present and future generations.”

A handful of other states have similar guarantees, and young people in Hawaii, Utah and Virginia have filed lawsuits that are slowly winding their way through courts. A federal case brought by young people, which had been stalled for years, is once again moving, heading toward a June trial in Oregon.

“It’s monumental,” said Badge Busse, 15, one of the Montana plaintiffs. “It’s a completely beautiful thing. Hopefully this will continue this upward trend of positivity.”

The Montana case, brought by plaintiffs ranging in age from 5 to 22, was the first of its kind to go to trial in the United States. While the state contended that Montana’s emissions are minuscule when considered against the rest of the globe’s, the plaintiffs argued that the state must do more to consider how emissions are contributing to droughts, wildfires and other growing risks to a state that cherishes a pristine outdoors.

Since 2011, state law has prevented officials from weighing “actual or potential impacts that are regional, national, or global in nature” when conducting environmental reviews of large projects. In May, while the case was pending, the Legislature updated the law to be even more explicit, blocking the state from “an evaluation of greenhouse gas emissions and corresponding impacts to the climate in the state or beyond the state’s borders” when deciding whether to approve new projects.

Montana has 5,000 gas wells, 4,000 oil wells, four oil refineries and six coal mines. The state is a “major emitter of greenhouse gas emissions in the world, in absolute terms, in per person terms, and historically,” Judge Kathy Seeley of Montana District Court wrote. Adding up the amount of fossil fuels extracted, burned, processed and exported by the state, the court found that Montana is responsible for as much carbon dioxide as produced by Argentina, the Netherlands or Pakistan.

In her ruling, the judge found that the state’s emissions “have been proven to be a substantial factor” in affecting the climate. Laws that limited the ability of regulators to consider climate effects were unconstitutional, she ruled.

She added that Montanans “have a fundamental constitutional right to a clean and healthful environment, which includes climate as part of the environmental life-support system.”

The trial, which took place in June, involved testimony from climate scientists who detailed how increases in greenhouse gas emissions as a result of human activity were already causing health and environmental damage, and how those effects were likely to accelerate unless action was taken.

Many of the young plaintiffs testified about effects they had witnessed — extreme weather events that threaten family ranching, warmed rivers and streams that harm fish, wildfire smoke that worsens asthma and disruptions to nature that interfere with Indigenous traditions. They also spoke of the toll on their mental health, and the anguish they felt as they considered a future dimmed by environmental collapse.

The government, which was given one week to present its defense, rested after just one day and did not call its main expert witness, surprising many legal experts.

While Montana has a long history of mining and oil, gas and coal interests carry sway in Helena, the state also has deep environmental traditions. In 1972, with widespread popular support for more protection of the state’s lands, the state Constitution was amended to say that the state should “maintain and improve a clean and healthful environment in Montana for present and future generations.”

The origins of the case stretch back nearly a decade. In 2011, Our Children’s Trust petitioned the Montana Supreme Court to rule that the state has a duty to address climate change. The court declined to weigh in, effectively telling the group to start in the lower courts. The lawyers at Our Children’s Trust identified potential plaintiffs, cataloged the ways in which Montana was being impacted by climate change and documented the state’s extensive support for the fossil fuel industry, which includes permitting, subsidies and favorable regulations.

“The legal community has been fearful that judges won’t understand these cases, and she blew that out of the water,” Ms. Olson said of Judge Seeley’s decision. “It was digestible, she understood it, and the findings were beautiful.”