The Mount Pleasant coal mine expansion in Muswellbrook has been cleared to proceed, despite concerns about its effects on climate and people's health.
The Land and Environment Court on Monday upheld the Independent Planning Commission's approval of the 444 million tonne project in September 2022.
MACH Energy's Mount Pleasant Optimisation Project would make the mine "one of the largest open-cut projects in NSW", able to extract coal until 2048.
The previous approval expires in 2026.
The Denman, Aberdeen, Muswellbrook and Scone Healthy Environment Group took legal action in December 2022 in a bid to overturn the commission's approval.
It argued the commission had failed to adequately consider the project's effect on climate, biodiversity, air quality and people's health.
Justice John Robson said there was "no doubt that the continuation of coal mining will contribute to the global total of greenhouse gas concentrations, which affects the climate system".
However, Justice Robson said the jurisdiction of the court was "confined to ensuring that the commission" met statutory provisions that govern its "functions and relevant powers".
"It is not the function of this court to undertake merits review of the commission's findings. This is a fundamental principle that will be reiterated throughout this judgement," he said.
As such, he said the environment group had "not established any of the grounds of review of the commission's decision to grant development consent to the project".
The environment group's treasurer Tony Lonergan said the court's decision was "extremely disappointing" and a "devastating blow to anyone who cares about a safe climate".
"What could be more important than protecting our unique natural heritage and biodiversity, or ensuring we can breathe clean air in Muswellbrook and the Upper Hunter," Mr Lonergan said.
"The continuation of coal mining in NSW prioritises the private interests of a few over the impacts of climate change on the environment and the future of our children and grandchildren."
He said planning laws were "clearly not climate ready", if projects "as harmful" as the Mount Pleasant project were allowed to proceed.
MACH Energy declined to comment.
However, the court judgement said MACH expressed "some doubt that the commission was obliged to consider the likely impacts" of scope three [indirect] greenhouse emissions.
But MACH said the commission "did take account of scope three emissions from the project as a likely negative impact".
It stated that the commission "expressly found" that "the mining of coal and its combustion is a major contributor to anthropogenic climate change, which has the potential to impact future generations".
"The commission understood that the project's emissions were a 'key issue' in deciding whether to grant development consent."
The environment group said the commission had failed to adequately consider "the newly discovered lizard", named Hunter Valley Delma.
The judgement said MACH "accepts that the legless lizard was encountered on the site when little was known about the species, and that further surveys and research are needed to effectively manage and protect the species in the wild".
"MACH submits that the commission formed the view that the species ... was capable of being managed through appropriate conditions of consent."
As for air quality, MACH said the commission found that "no significant adverse social impacts" were "anticipated".