Jack Phillips objected to baking a cake for the couple on religious grounds. The Supreme Court overturned a Colorado ruling that his business must bake the cake or face severe consequences.

The Supreme Court ruled 7-2 in favor of a Colorado cake baker on Monday who objected to baking a custom wedding cake for a same-sex couple on religious grounds.

Justice Anthony Kennedy wrote in the majority opinion that Colorado can protect gay people, but the laws protecting them “must be applied in a manner that is neutral toward religion.”

Kennedy pointed to the hostility the baker, Jack Phillips, faced from the Colorado Civil Rights Commission, which ordered that his Masterpiece Cakeshop must bake a cake for the couple, amend his store’s policy, re-educate his employees, and file quarterly obedience reports — or face crippling fines and even jail time. You can read more about Phillips’s story here.

“The Commission’s hostility was inconsistent with the First Amendment’s guarantee that our laws be applied in a manner that is neutral toward religion,” Kennedy wrote. “Phillips was entitled to a neutral decision maker who would give full and fair consideration to his religious objection as he sought to assert it in all of the circumstances in which this case was presented, considered, and decided.”

“Jack serves all customers; he simply declines to express messages or celebrate events that violate his deeply held beliefs,” said Kristen Waggoner, senior counsel at the Alliance Defending Freedom, which represented Philips. “Government hostility toward people of faith has no place in our society, yet the state of Colorado was openly antagonistic toward Jack’s religious beliefs about marriage. The court was right to condemn that. Tolerance and respect for good-faith differences of opinion are essential in a society like ours. This decision makes clear that the government must respect Jack’s beliefs about marriage.”