The Supreme Court ruled Wednesday that legally married, same-sex couples should get the same federal benefits as heterosexual couples.
The court invalidated a provision of the federal Defense of Marriage Act that has prevented married gay couples from receiving a range of tax, health and retirement benefits that are generally available to married people. The vote was 5-4.
Justice Anthony Kennedy wrote the majority opinion.
Same-sex marriage has been adopted by 12 states and the District of Columbia. Another 18,000 couples were married in California during a brief period when same-sex unions were legal there.
The court has yet to release its decision on California's ban on same-sex marriage.
"Under DOMA, same-sex married couples have their lives burdened, by reason of government decree, in visible and public ways," Kennedy said.
"DOMA's principal effect is to identify a subset of state-sanctioned marriages and make them unequal," he said.
He was joined by the court's four liberal justices.
Chief Justice John Roberts and Justices Samuel Alito, Antonin Scalia and Clarence Thomas dissented.
Scalia read his dissent aloud. Scalia said the court should not have decided the case.
But, given that it did, he said, "We have no power under the Constitution to invalidate this democratically adopted legislation."
President Barack Obama tweeted his reaction for Wednesday's historic ruling.
"Today's DOMA ruling is a historic step forward for #MarriageEquality. #LoveIsLove," tweeted @BarackObama.
The law was passed in 1996 by broad majorities in the House of Representatives and the Senate, and signed into law by Democratic President Bill Clinton. Since then, many lawmakers who voted for the law and Clinton have renounced their support.
Supporters of same sex marriage gathered on the steps of City Hall to celebrate the news Wednesday night.
One of the many speakers was Kathy Hubbard. Introduced as 'The First Lady of Houston,' Hubbard said she and Mayor Annise Parker have been in a committed relationship for more than 23 years. Now, she's looking forward to calling Parker her spouse.
"Annise and I have lived out of the closet all our lives together," Hubbard said. "In fact, we're so far out of the closet I feel like we live on the front lawn."
Parker couldn't attend the rally because of a scheduling conflict. Local 2 caught up with her and she said the Supreme Court's ruling is good news.
"I'm very excited about the ruling. I would like to see what the implications are. I hope it means that someday we have full marriage equality in this country," she said.