WASHINGTON (Reuters) - Churches and other religious entities cannot be flatly denied public money even in states where constitutions explicitly ban such funding, the U.S. Supreme Court ruled on Monday in a major religious rights case that narrows the separation of church and state.

Activists rally outside U.S. Supreme Court after the Court sided with Trinity Lutheran Church, which objected to being denied public money in Missouri, in Washington, U.S., June 26, 2017. REUTERS/Yuri Gripas

The justices, in a 7-2 ruling, sided with Trinity Lutheran Church of Columbia, Missouri, which sued after being denied access to a state grant program that helps nonprofit groups buy rubber playground surfaces made from recycled tires.

Conservative Chief Justice John Roberts, writing for the court’s majority, said that “the exclusion of Trinity Lutheran from a public benefit for which it is otherwise qualified, solely because it is a church, is odious to our Constitution” and “cannot stand.”

Missouri’s constitution prohibits “any church, sect or denomination of religion” or clergy member from receiving state money, language that goes further than the U.S. Constitution’s separation of church and state.

Three-quarters of the U.S. states have provisions similar to Missouri’s barring funding for religious entities.

Liberal Justice Sonia Sotomayor wrote a dissenting opinion saying the court had swept away legal precedents that allow for limits on state funding of churches. Fellow liberal Ruth Bader Ginsburg also dissented.

“This case is about nothing less than the relationship between religious institutions and the civil government - that is between church and state. The court today profoundly changes that relationship by holding for the first time that the Constitution requires the government to provide public funds directly to a church,” Sotomayor wrote.

The ruling could help religious organizations nationwide win public dollars at least for certain purposes, such as health and safety. It also could buttress the case for using publicly funded vouchers to send children to religious schools rather than public schools.

A challenge to a 2015 court decision invalidating a Colorado voucher program is pending before the justices, awaiting the Trinity Lutheran case’s outcome. The court could act on that case as soon as Tuesday. Republican President Donald Trump’s education secretary, Betsy DeVos, is a prominent supporter of such “school choice” plans.

Roberts, in a footnote in the ruling, said, “This case involves express discrimination based on religious identity with respect to playground resurfacing. We do not address religious uses of funding or other forms of discrimination.”

White House spokesman Sean Spicer called the ruling a “significant victory for religious liberty and an affirmation of the First Amendment rights of all Americans.”

“This ruling reaffirms that the government cannot discriminate against individuals or organizations simply because they or their members hold religious beliefs,” Spicer added.

The dispute pitted two provisions of the U.S. Constitution’s First Amendment against each other: the guarantee of the free exercise of religion and the Establishment Clause, which requires the separation of church and state.

The discrimination against religious exercise in this case was Missouri’s refusal to allow Trinity Lutheran “solely because it is a church” to compete with secular organizations for a grant, Roberts wrote. Trinity Lutheran, which runs a preschool and daycare center, had wanted a safer surface for its playground.

‘COMMONSENSE PRINCIPLE’

“The Supreme Court’s decision today affirms the commonsense principle that government isn’t being neutral when it treats religious organizations worse than everyone else,” said David Cortman, senior counsel at the Alliance Defending Freedom conservative Christian legal group who argued the case.

“Equal treatment of a religious organization in a program that provides only secular benefits, like a partial reimbursement grant for playground surfacing, isn’t a government endorsement of religion,” Cortman added.

Trinity Lutheran argued that Missouri’s policy violated its right to exercise religion as well as the U.S. Constitution’s promise of equal protection under the law. Missouri argued there was nothing unconstitutional about its grant program, noting that Trinity Lutheran remained free to practice its faith however it wants despite being refused state funds.

Daniel Mach, director of the American Civil Liberties Union’s program on freedom of religion and belief, expressed disappointment in the ruling.

“Religious freedom should protect unwilling taxpayers from funding church property, not force them to foot the bill. The court’s ruling, however, focuses specifically on grants for playground resurfacing, and does not give the government unlimited authority to fund religious activity,” Mach said.

The justices overturned a 2015 ruling by the St. Louis-based 8th U.S. Circuit Court of Appeals in 2015 upheld a trial court’s dismissal of the suit.

Just before the April oral argument, Missouri’s Republican governor, Eric Greitens, reversed the state policy that had banned religious entities from applying for the grant money.