A federal appeals panel in San Francisco ruled Tuesday that California’s Proposition 8, which bans same-sex marriage, is unconstitutional, a decision that could lead to the Supreme Court’s consideration of the controversial social issue.

By a vote of 2 to 1, the panel overturned the measure, which in 2008 amended the state’s Constitution to limit marriage to a man and a woman.

“Proposition 8 serves no purpose, and has no effect, other than to lessen the status and human dignity of gays and lesbians in California, and to officially reclassify their relationships and families as inferior to those of opposite-sex couples,” U.S. Circuit Judge Stephen Reinhardt wrote. “The Constitution simply does not allow for laws of this sort.”

The panel took a narrow route in knocking down California’s prohibition and did not address whether same-sex couples have a federal constitutional right to marry. Such unions are unlikely to resume in the nation’s most populous state until the appeals process is completed.

But it was a significant development in a contentious national battle over gay rights, including the ability to serve openly in the military. Besides California, 28 states have constitutional amendments that ban same-sex marriage, and 12 others have laws that restrict unions to one man and one woman.

Six states and the District of Columbia allow gay couples to marry, and three others are considering joining them. Polls show a striking generational difference in acceptance, with young people far more in favor of allowing same-sex unions.

There is a partisan difference as well. And if the issue reaches the Supreme Court, as opponents of same-sex-marriage want, the arguments could occur in the fall when the nation is consumed with a presidential election.

The ideological differences were apparent on the three-judge panel. Reinhardt, a Jimmy Carter appointee who is considered one of the nation’s most liberal appellate judges, was joined by Judge Michael Daly Hawkins, appointed by President Bill Clinton. Judge N. Randy Smith, a conservative appointed by President George W. Bush, dissented.

But the majority did not issue a broad ruling on the constitutionality of same-sex marriage. Instead, it focused on the fact that gay couples in California for a brief time had the right to marry, and that Proposition 8 took that away.

In 2008, the California Supreme Court ruled 4 to 3 that same-sex couples could not be denied the right to wed, and over the next five months, about 18,000 such couples took marriage vows. But that fall, 52 percent of California voters supported Proposition 8, amending the state Constitution to validate “only a marriage between a man and a woman.”

Reinhardt said this “taking away” of a right by the majority was not allowed.

“By using their initiative power to target a minority group and withdraw a right that it possessed, without a legitimate reason for doing so, the people of California violated the Equal Protection Clause” of the federal Constitution, Reinhardt wrote.

He based the ruling on the Supreme Court’s 1996 decision in Romer v. Evans . It involved an amendment to the Colorado Constitution that prohibited the state or local jurisdictions from outlawing discrimination against gays. It was in response to local governments that had extended such protection.

But the Supreme Court said it was “not in our constitutional tradition” to enact laws that single out “a certain class of citizens for disfavored legal status.”

The Romer decision was written by Justice Anthony M. Kennedy, who has been the deciding vote in the high court’s recent decisions supporting gay rights. Reinhardt’s reliance on Romer suggests that the Supreme Court could settle California’s same-sex-marriage issue in an equally narrow way, without confronting whether there is a constitutional right to marry.

In his dissent, Smith said that he did not think the Romer decision mandated the outcome in the current case, and that the proper role for the judiciary is to defer to the view that the proposition advanced “legitimate state interests.”

Reinhardt and Hawkins, however, said the supporters of Proposition 8 proved no legitimate state interests. Because the amendment allowed gay couples all rights except marriage, they said, it “could not have reasonably been enacted to promote childrearing by biological parents, to encourage responsible procreation, to proceed with caution in social change, to protect religious liberty or to control the education of schoolchildren.”

Andrew Pugno, general counsel for the ProtectMarriage.com coalition, which supported Proposition 8, said the panel’s decision was “no surprise.”

“Ever since the beginning of this case, we’ve known that the battle to preserve traditional marriage will ultimately be won or lost not here, but rather in the U.S. Supreme Court,” Pugno said.

He said his group has not decided whether to ask the full U.S. Court of Appeals for the 9th Circuit to review the decision, or take the case directly to the Supreme Court.

The attorneys who argued on behalf of gay couples — Theodore B. Olson, who was solicitor general under President George W. Bush, and Democratic lawyer David Boies — said the decision marks a milestone, but they had slightly different takes on whether it would command a Supreme Court review.

Boies said the court might let the narrow ruling stand, because it would affect only marriages in California. He said he thought the court would be “somewhat less likely to take it.”

But Olson noted that although the ruling was narrow, the reasoning behind it was bold. The decision “ringingly reaffirmed the right to equality, the fundamental right to marriage,” he said.

Even if Proposition 8 supporters went directly to the Supreme Court and the justices agreed to take the case, they probably would not rush to hear the case before the court term ends in June.

The appeals panel’s decision upheld a 2010 ruling by former U.S. District Judge R. Vaughn Walker. All three judges rejected an argument from Proposition 8 proponents that Walker should have recused himself from the case because he disclosed after trial that he is gay and had been in a relationship for 10 years.

The case was brought by two same-sex couples, Kris Perry and Sandy Stier, and Paul Katami and Jeff Zarrillo.

Besides the District, same-sex marriage is allowed in Connecticut, Iowa, Massachusetts, New Hampshire, New York and Vermont.

Staff writer Joshua Hicks contributed to this report.