Gay marriage advocates vowed to appeal a state appeals court ruling upholding California's ban on same-sex weddings — a decision that would be a critical defeat for their cause if it stands.

In reversing the March 2005 ruling of a San Francisco trial judge, the 1st District Court of Appeal on Thursday dealt another setback to the movement to expand gay marriage beyond Massachusetts.

This summer, high courts in New York and Washington state also refused to strike down laws prohibiting same-sex marriage.

But unlike in those states, gay activists in California still have another chance to get the state's marriage laws overturned. They and their opponents have said they expect the California Supreme Court to settle the issue.

"While we are disappointed that the Court of Appeal ruled against our families, we are confident that we will prevail and that the California dream will be available to all," said Geoff Kors, executive director of Equality California.

Opponents of gay marriage praised the court's decision.

"The court understood that marriage has a meaning, and that unless you redefine marriage all the arguments the other side have made are meaningless," said Glen Lavy, an attorney for Alliance Defense Fund, which asked the appeals court to overturn the lower court ruling.

In a 2-1 decision, the appeals court agreed with the state's attorney general, who argued that it is up to the Legislature — not the courts — to change the traditional definition of marriage as a union between a man and a woman.

"We conclude California's historical definition of marriage does not deprive individuals of a vested fundamental right," the court majority said. "The time may come when California chooses to expand the definition of marriage to encompass same-sex unions. That change must come from democratic processes, however, not by judicial fiat."

The justices said the state has gone a long way toward promoting equality for same-sex couples through its strong domestic partner law, which gives registered couples the same rights as married spouses.

They rejected arguments from gay marriage proponents that such a "separate, but equal" system was discriminatory.

"It is rational for the Legislature to preserve the opposite-sex definition of marriage, which has existed throughout history," Justice William McGuiness wrote.

In a strongly worded dissent, Justice Anthony Kline scoffed at what he said was his colleagues' suggestion that same-sex couples should not be entitled to marry now simply because they had not been permitted to in the past.

"The fact that same-sex couples have traditionally been prohibited from marrying is the reason this lawsuit was commenced," he wrote.

Since 2004, when Massachusetts became the first state to legalize gay marriage, advocates have seen California as one of their best hopes for expanding the movement.

The state is home to more same-sex couples than any other and is one of 26 with statutes limiting marriage to a man and a woman. Another 19 states passed constitutional amendments barring gay marriage after Massachusetts gays won the right to wed.