Although a handful of states have legalized same-sex marriage through their legislatures or as the result of court decisions, voters had rejected the practice all 32 times it had been on the ballot, dating back to 1998.

Tuesday's victories for gay-rights advocates mark a rapid reversal in public opinion on the issue. In 2004, same-sex marriage was so unpopular that many observers believed that the presence of the issue on swing-state ballots helped drive conservative turnout for then-President George W. Bush. 

But this year, the Democratic Party endorsed same-sex marriage in its party platform, and President Obama announced his personal support for the issue.

Tuesday's votes could also embolden the Supreme Court, which might soon consider constitutional challenges to same-sex marriage bans.

"We look forward to all the marriages we’ll celebrate in 2013, even as we turn our momentum into more victories across the country,” Shawn Werner, director of political operations at Freedom to Marry and an adviser to the Maryland campaign, said in a statement.