Jubilation echoed from coast to coast on Wednesday from gay rights advocates when the Supreme Court dismissed a defense of Proposition 8 that outlawed same-sex marriage in California and ruled that the federal Defense of Marriage Act (DOMA), signed by President Bill Clinton in 1996, is unconstitutional.

While the ideological lines were clear in the decisions on affirmative action on Monday, 7-1, and 5-4 on Voting Rights on Tuesday, the 5-4 votes on DOMA and Proposition 8 had outcomes that were not along party lines. Chief Justice John Roberts wrote the majority opinion in the latter ruling, and he was joined by Justices Ruth Bader Ginsburg, Stephen Breyer, Elena Kagan and Antonin Scalia.

Justice Anthony Kennedy, the usual swing vote on the court, wrote the majority opinion for DOMA, and he was joined by the liberal wing of the court.

The range of celebrants of the decision extended from President Barack Obama to Ben Affleck. “Today’s DOMA ruling is a historical step forward for marriage equality,” the president tweeted.

“Big news from the Supreme Court,” was Affleck’s Twitter response. “Goodbye DOMA and Prop 8 and hello equality.”

In a more official release, the president said, “When all Americans are treated as equal, no matter who they are or whom they love, we are all more free.”

More expansively, Obama said: “I applaud the Supreme Court’s decision to strike down the Defense of Marriage Act. This was discrimination enshrined in law. It treated loving, committed gay and lesbian couples as a separate and lesser class of people. The Supreme Court has righted that wrong, and our country is better off for it. We are a people who declared that we are all created equal—and the love we commit to one another must be equal as well.

“This ruling is a victory for couples who have long fought for equal treatment under the law; for children whose parents’ marriages will now be recognized, rightly, as legitimate; for families that, at long last, will get the respect and protection they deserve; and for friends and supporters who have wanted nothing more than to see their loved ones treated fairly and have worked hard to persuade their nation to change for the better,” he concluded.

Married same-sex couples will now be federally recognized in 13 states and the nation’s capital.