The battle to drain the reservoir in Yosemite’s Hetch Hetchy Valley reignited Wednesday as critics of the historic dam told a panel of judges in Fresno that their legal case to raze it should proceed, despite an earlier decision to dismiss the suit.

In California’s Fifth District Court of Appeal, attorneys for the group Restore Hetch Hetchy reiterated their longtime argument that San Francisco should not be operating a reservoir in a national park because it violates a provision of the state Constitution requiring reasonable water use.

Calling the O’Shaughnessy Dam an inappropriate and illegal diversion of water, the Berkeley group has insisted that San Francisco quench its thirst elsewhere, and not bury a pristine Sierra valley.

“In putting in that dam and operating it over the years, they absolutely have to comply with California water law,” attorney Mike Lozeau told the appellate judges, who did not immediately rule on Restore Hetch Hetchy’s appeal.

Wednesday’s hearing came two years after a Tuolumne County Superior Court judge tossed the group’s lawsuit, saying the reservoir was properly authorized. The court said San Francisco officials had received permission to move forward with the project under federal statute, which superseded state law.

The court also said that efforts to remove the dam should have begun decades ago.

The reservoir was constructed in 1923, as San Francisco sought to develop a water supply fit for the 20th century. Today, the lake anchors a sprawling water-supply system that serves 2.7 million residents and businesses in more than a dozen Bay Area communities. It also generates hydroelectric power for San Francisco municipal buildings.

City officials have said it’s silly to try to turn back the clock. They cite the reservoir’s importance to the growing Bay Area, especially today, amid the increasing uncertainty of water supplies in an era of climate change.

The opposition’s argument on Wednesday sought to downplay the authority that San Francisco had in moving ahead with the reservoir a century ago.

According to Lozeau, the Raker Act of 1913, the federal legislation that enabled the O’Shaughnessy Dam to take shape on national park land, merely authorized a right of way. In proceeding with the project, he said, Congress expected the city to follow state statute requiring responsible water use.

“They intended that California water law would apply, even if it conflicted with the directives” of the Raker Act, Lozeau said. “The question right now is, is it a reasonable level of diversion in this day and age?”

Attorneys for San Francisco countered that the issue had been settled. They said that the Raker Act gave the city specific permission to build a reservoir, not just a right of way, and they agreed with the trial court that federal law preempted state water requirements.

The dispute over the dam began long ago, even before the city broke ground on it.

Naturalist John Muir likened the Hetchy Hetchy area, with its granite domes and towering waterfalls high above the Tuolumne River, to Yosemite Valley. He did not want to see the area used as a municipal water supply. With support of the budding Sierra Club, opponents mounted what became the nation’s first major environmental fight.

That revolt, however, proved unsuccessful. San Francisco’s strong lobby was able to convince Washington that the city needed a more robust water supply in the aftermath of the 1906 earthquake and subsequent fires. President Woodrow Wilson signed the Raker Act on Dec. 19, 1913.

More recent efforts to take back the valley have the support of other environmental groups, former Yosemite National Park superintendents and such celebrities as Harrison Ford. But they’ve been slow to gain wider backing.

While supporters of the effort insist that much of the water in the reservoir can be captured in other reservoirs, including the giant Don Pedro Reservoir downstream, city officials have said such a proposal is too costly.

Six years ago, Restore Hetch Hetchy qualified an initiative for the San Francisco ballot that would have required the city to seriously explore removing the dam. The measure was defeated by city residents.

“San Francisco voters overwhelmingly rejected the idea of draining Hetch Hetchy Reservoir in 2012 because it was a terrible idea,” City Attorney Dennis Herrera said in a statement. “It’s still a terrible idea today.”

In 2015, the group took the issue to court, but Tuolumne County Superior Court Judge Kevin Seibert dismissed the suit the following year. Restore Hetch Hetchy immediately appealed.

The Fifth District Court did not indicate when it would rule on the appeal, with one judge simply saying “shortly.” Whatever the verdict, the losing side is expected to pursue the case to the state Supreme Court.

Kurtis Alexander is a San Francisco Chronicle staff writer. Email: kalexander@sfchronicle.com Twitter: @kurtisalexander