As news of the ruling broke, hundreds of people descended on county clerk offices around the state to request marriage licenses. At the Salt Lake County Clerk's Office, a First Baptist pastor was on hand to conduct wedding ceremonies. Michael Ferguson, 32, and Seth Anderson, 31 were the first same-sex couple to receive a license there and be married.
Hours later, the Utah attorney general's office appealed the decision to the 10th Circuit Court of Appeals in Denver and also filed a motion asking Shelby to stay the ruling while it seeks to defend Utah's Amendment 3.
"The federal district court's ruling that same-sex marriage is a fundamental right has never been established in any previous case in the 10th Circuit," it said.
The appellate court handles cases for Oklahoma, Kansas, New Mexico, Colorado, Wyoming and Utah. The New Mexico Supreme Court affirmed the right to same-sex marriage on Thursday.
Utah Gov. Gary Herbert released a statement that said he was "very disappointed an activist federal judge is attempting to override the will of the people of Utah" and said he would work with Acting Attorney General Brian L. Tarbet "to determine the best course to defend traditional marriage within the borders of Utah."
Meanwhile, any marriage licenses issued before a possible stay is granted will be valid, according to a plaintiff's attorney. But the state disputes that in its appeal.
Among those married in Salt Lake County on Friday afternoon: Kody Partridge, 47, and Laurie Wood,one of the three couples named as plaintiffs in the lawsuit that challenged Amendment 3.
The ruling is the first federal decision on a state law banning same-sex marriages or denying recognition of legal same-sex marriages since the U.S. Supreme Court's landmark decision this summer that struck down the federal Defense of Marriage Act (DOMA).
The Utah judge ruled just 16 days after he heard arguments in the case and well before his self-imposed deadline to render a decision by Jan. 7, when the next hearing in the matter was to be held, relying on extensive briefs filed in the case by both sides.
"It feels unreal," said Moudi Sbeity, who with his partner Derek L. Kitchen were plaintiffs in the case. "I'm just very thrilled that Derek and I will be able to get married soon, if all goes well and the state doesn't appeal."
The pair make and sell Mediterranean-style spreads at farmers markets throughout Utah, which Sbeity said would be an ideal setting for their wedding.
The other plaintiffs in the lawsuit are Karen Archer, 67, and Kate Call, 60. Archer and Call already have a marriage license from Iowa, but joined the lawsuit to protest Utah's refusal to recognize that marriage. The other two couples applied for a license from the Salt Lake County Clerk's office in March but were denied one.
Attorneys Peggy A. Tomsic and James E. Magleby, who represented the plaintiffs, hailed what they said was a historic, courageous decision to bring marriage equality to Utah for all same-sex couples "who desire to marry or have their legal marriage from another state recognized in Utah."
If the decision stands, it will "provide legal precedent to support other plaintiffs's constitutional challenges to similar state laws in the remaining states where there is marriage inequality," they said in a statement.
Tomsic said she went to the Salt Lake County Clerk's Office Friday afternoon and saw the long line of same-sex couples trying to get a marriage license.
"It made me sad and happy at the same time," she said. "Happy that same-sex couples finally have the same rights as every other citizen of Utah and the U.S. and sad that it has taken so long."
Across Utah, county clerks had varying responses to the decision. By 3 p.m., Salt Lake County District Attorney Sim Gill had advised Clerk Sherrie Swensen to begin issuing marriage license applications to same-sex couples immediately.
"Unless there is a change, the current state of the law is that we cannot prohibit it," Gill said, but then warned, "This is a moving thing."
Clerks in Utah, Weber and Davis counties initially said they were not issuing licenses pending instruction from county attorneys. But Davis County Attorney Troy S. Rawlings later told clerks to abide by the ruling.
"The decision announced today, unless and until a stay is granted or Judge Shelby is overturned, is the law of the land," he said in a memo. "We will also consider seeking leave to file an amicus brief supporting Utah's legal right to define marriage."
Sean Reyes, Bob Smith and Tarbet, all candidates to replace former Attorney General John Swallow, who resigned under investigation earlier this month, have said they would not simply accept a federal ruling legalizing same-sex marriage.
The Church of Jesus Christ of Latter-day Saints, which remained on the sidelines during the district court process unfolding in its home state, broke that silence Friday.
"The church has been consistent in its support of traditional marriage while teaching that all people should be treated with respect," said spokesman Cody Craynor. "This ruling by a district court will work its way through the judicial process. We continue to believe that voters in Utah did the right thing by providing clear direction in the state constitution that marriage should be between a man and a woman, and we are hopeful that this view will be validated by a higher court."
Other reactions cross the political and religious spectrum. While the LDS Church voiced support for the state's position, Mormons for Equality called it a "thrilling" confirmation of the right to civil marriage. The Human Rights Campaign called it a recognition of "fundamental equality" while the National Organization on Marriage said the decision was a "travesty of justice" and an example of "vetoing the voters from the bench."
Shelby said he agreed that marriage has traditionally been left to states to regulate, as Utah argued, but those laws must comply with the Constitution.
"The issue the court must address in this case is not who should define marriage, but the narrow question of whether Utah's current definition of marriage is permissible under the Constitution," the judge said.
Shelby acknowledged the politically charged climate that surrounds the issue and said that was particularly true in Utah, where 66 percent of voters approved the ban nearly a decade ago.
"It is only under exceptional circumstances that a court interferes with such action," Shelby said. "But the legal issues presented in this lawsuit do not depend on whether Utah's laws were the result of its Legislature or a referendum, or whether the laws passed by the widest or smallest of margins."
The judge noted both parties drew arguments from the U.S. Supreme Court's decision in United States v. Windsor, which struck down DOMA but did not resolve the issue in the context of state laws banning same-sex marriage. Shelby said Justice Antonin Scalia predicted in his dissent that would come next as plaintiffs raised similar claims about harms due to state laws.
But Shelby said other decisions addressed the "tension" between a state's right to regulate marriage and individual liberty and equal protection rights, among them 1967's Loving v. Virginia that ended bans on interracial marriage. Such rulings held that individual rights take precedence over states' rights when the two are in conflict, the judge said.
"Given the importance of marriage as a fundamental right and its relation to an individual's rights to liberty, privacy, and association, the Supreme Court has not hesitated to invalidate state laws pertaining to marriage whenever such a law intrudes on an individual's protected realm of liberty," Shelby said.
The state's ban rendered the right to choose one's marriage partner "as meaningless as if the state recognized the plaintiffs' right to bear arms but not their right to buy bullets," the judge said.
Shelby took issue with the state's argument that the plaintiffs "do not possess the qualifications" to enter a marriage relationship, saying there is "no dispute that the plaintiffs are able to form a committed relationship with one person to the exclusion of all others" and to raise children within that union if they desire.
Shelby said the state's argument about the ties between marriage, procreation and optimal child-rearing were not compelling, nor was its assertion that the plaintiffs were seeking a new right.
"However persuasive the ability to procreate might be in the context of a particular religious perspective, it is not a defining characteristic of conjugal relationships from a legal and constitutional point of view," the judge said. "The state's position demeans the dignity not just of same-sex couples, but of the many opposite sex couples who are unable to reproduce or who choose not to have children."
What same-sex couples seek is simply the same right "currently enjoyed by heterosexual individuals: the right to make a public commitment to form an exclusive relationship and create a family with a partner with whom the person shares an intimate and sustaining emotional bond," he said.
Shelby also gave a nod to Utah's religious majority. The judge said that while the state did not present an argument based on religious freedom, his decision does not mandate any change for religious institutions; those who oppose such marriages may continue to do so, he said.
"If anything, the recognition of same-sex marriage expands religious freedom because some churches that have congregations in Utah desire to perform same-sex wedding ceremonies but are currently unable to do so," he said.
With the ruling, Utah becomes the 18th state where same-sex marriage has become legal through either court decisions, legislation or referendums. The District of Columbia also allows same-sex marriage.
The ACLU of Utah filed an amicus brief in the case and legal director John Mejia said Friday the organization was "thrilled" by the decision.
"We think that it was a discriminatory law that only served to deny loving and committed couples the protection and dignity of marriage," he said. "We congratulate the brave plaintiffs for making such a historic stand and their legal team for putting up such a great fight."
Cliff Rosky, University of Utah law professor and chairman of the board for Equality Utah, said he is optimistic Shelby's ruling will survive appeal.
"We are thrilled that our federal courts have finally recognized that Utah's Amendment 3 is unconstitutional. It demeans the dignity of gay relationships," Rosky said. "[The ruling] is cautious and thoughtful, based explicitly on the Supreme Court's ruling from this summer. I fully expect it to be upheld on appeal.
"When that happens, people will soon enjoy the freedom to marry in Utah and all 50 states."
Utah Democratic Chairman Jim Dabakis, who is gay, married his longtime partner Friday afternoon and called the decision reasonable. He noted the generational divide on the issue where young people, including younger Republicans, are more accepting of gay marriage than older people.
"What we need to do is a little hand holding with Utahns of a certain generation who really don't understand that there is no need to feel threatened by gay people, that we are just like everybody else," he said.
And Dabakis said there needs to be a recognition that civil marriage and religious marriage are not necessarily the same thing.
"I don't believe any religion should be coerced into performing a marriage they are not comfortable with and conversely no religion should be able to take away a civil right that should be available across the country," he said.
Tribune reporter Erin Alberty, Matt Canham, Peggy Fletcher Stack and Matt Piper contributed to this report.