This file photo shows Dave Mullins, right, sitting for a portrait with his husband Charlie Craig, in Denver in June, 2013. Brennan Linsley/AP

The case involves Charlie Craig and David Mullins, who said Phillips refused to bake a wedding for their wedding celebration when they went to his shop in 2012. The couple was wed in Massachusetts, one of 16 U.S. states that have legalized same-sex marriage , but wanted to have a celebration of their nuptials in Colorado.

"This view, however, fails to take into account the cost to society and the hurt caused to persons who are denied service simply because of who they are."

"At first blush, it may seem reasonable that a private business should be able to refuse service to anyone it chooses," Spencer wrote in his 13-page ruling.

Administrative Law Judge Robert Spencer ordered Jack Phillips, owner of Masterpiece Cakeshop in suburban Denver, to accommodate same-sex couples or face fines and other possible penalties.

A Colorado bakery owner illegally discriminated against a gay couple when he refused to make a wedding cake for the pair last year because of his Christian religious beliefs, a judge ruled Friday.

Colorado allows civil unions for same-sex couples, but defines marriage as between one man and one woman. Phillips refused to bake the cake, saying his Christian beliefs prevented him from doing so.

Nicolle Martin, an attorney for Masterpiece Cakeshop, said the judge's order puts Phillips in an impossible position of going against his Christian faith.

"He can't violate his conscience in order to collect a paycheck," she said. "If Jack can't make wedding cakes, he can't continue to support his family. And in order to make wedding cakes, Jack must violate his belief system. That is a reprehensible choice. It is antithetical to everything America stands for."

The American Civil Liberties Union filed a complaint with the Colorado Civil Rights Division, which ruled that Phillips had violated a state law barring discrimination at public accommodations based on race, gender or sexual orientation. On Friday, Spencer upheld the commission's findings.

Mullins said in a statement it was "offensive and dehumanizing" when he and Craig were denied service at the bakery. "No one should fear being turned away from a public business because of who they are," he said.

Mullins said he and Craig are "ecstatic" about the decision.

"To a certain extent, though, I don't think that this is necessarily a surprise," he said. "We thought it was pretty clear cut that he had discriminated against us."

Phillips has not decided whether to appeal to a higher court, said his attorney, Nicolle Martin.

"If the government can take away your First Amendment rights, there's nothing they can't take away from you," she said.

A similar case is pending in Washington state, where a florist is accused of refusing service for a same-sex wedding. In New Mexico, the state Supreme Court ruled in August that an Albuquerque business was wrong to decline to photograph a same-sex couple's commitment ceremony.

Al Jazeera and wire services