Domestic partners John Lewis and Stuart Gaffney were excited, saying they can finally be newlyweds after 21 years together.
"California history is being made today, and it is a love story," said Lewis.
"You have one of the most important Supreme Courts in the country saying gay people matter every bit as much as everyone else," said Kate Kendall from the National Center for Lesbian Rights.
The 4-3 decision came from a panel of justices appointed by six Republican governors. In the majority opinion, Chief Justice Ron George in essence said separate was not equal -- domestic partnerships were not the same as marriage.
George wrote, "Our state now recognizes that an individual's capacity to establish a loving and long-term committed relationship with another person and responsibly care for and raise children does not depend upon the individual's sexual orientation."
Conservative lawmakers in Sacramento were surprised at the ruling, saying the justices overreached their powers. Laws are made by the legislature, or by the people when they vote on initiatives.
In this case, voters passed Proposition 22 eight years ago, which said only marriages between a man and a woman are valid and recognized in California.
"What they've decided is that they themselves are the legislative body, and they've basically made law. And, of course, nobody likes it when we get an activist judiciary making law," said Assemblyman Chuck DeVore, R-Irvine.
Same sex marriage opponents are already trying to qualify a ballot measure for November amending the state constitution to ban gay marriages. Governor Arnold Schwarzenegger, R-California, said he would not support that.
The cases were brought by the city of San Francisco, two dozen gay and lesbian couples, Equality California and another gay rights group in March 2004. They were filed after the court halted San Francisco's month-long same-sex wedding march that took place at Mayor Gavin Newsom's direction.
The justices had appeared divided on the issue when they heard arguments in March, with some justices asking if it should be up to state lawmakers or voters to legalize same-sex marriages.
Supporters celebrated the decision at the Gay and Lesbian Center in Hollywood.
"It's just a historic moment for our movement. It's a great day for all of Californians who believe in everything that California stands for, which is that everybody should be treated equally, that this is the land of opportunity and fairness and freedom for all of us," said Lorri Jean, CEO of the Gay and Lesbian Center.
Opponents of gay marriage say they have not given up and are pushing toward November. They are trying to get another initiative on the ballot banning gay marriage.
"Finally, the court has spoken and overturned it, and that's really critical in the movement toward full marriage. We still have to get past November," said Robert Blackmun, a local who supports the ruling.
Supporters of gay marriage say that is their next fight and will be working hard to stop that action, but for now, they are celebrating Thursday's ruling.
- Complete text of Calif. Supreme Court decision (PDF)
- U.S. Map showing marriage legislation
- Legal developments in same-sex marriage
ABC7's Leanne Suter and The Associated Press contributed to this report