Today, the Supreme Court reaffirmed what most Americans no doubt take for granted, that the Constitution prohibits religious discrimination. The 5-4 divide among the justices in Espinoza v. Montana Department of Revenue, however, shows that religious freedom is not fully secure in America.

Different state and local governments have developed “school choice” programs that make parents more financially able to choose the best education for their children. Even though religious schools often provide better education, and at lower cost, activists often fight, in legislatures and in courts, to exclude them from school choice programs.

In Zelman v. Simmons-Harris, the Supreme Court held in 2002 that including religious schools in such programs does not amount to an “establishment of religion” prohibited by the First Amendment. The Espinoza case revisits this dispute in a different way.

The Montana Legislature enacted a program that provided a small tax credit for contributions to organizations that provide scholarships to help pay private school tuition. To qualify for receiving scholarship money under this program, schools must meet basic accreditation, safety, and testing requirements.

Montana, however, is one of 38 states with constitutions that prohibit any “direct or indirect appropriation or payment from any public fund or monies … for any sectarian purpose or to aid any … school … controlled in whole or in part by any church, sect, or denomination.”

This provision is often called the “Blaine Amendment,” named for Rep. James Blaine, R-Maine, who offered it in 1875 as an amendment to the U.S. Constitution. That effort, which was motivated in part by anti-Catholic bias, failed in Congress, but this provision found its way into most state charters.

Against the advice of the Montana attorney general, the Montana Department of Revenue issued a rule that, under this provision, awards from the scholarship program could not be used to pay tuition at religious schools.

Three mothers with children who wanted to use scholarship money at religious schools sued. They did not challenge this constitutional provision directly, but said that its application to them violated their First Amendment right to freely exercise religion.

The Montana Supreme Court decided that the scholarship program violated the state constitution, but the Montana Department of Revenue exceeded its authority in issuing the exclusion rule. The court concluded that the only way to resolve the issue was to invalidate the entire program.

Today, in an opinion by Chief Justice John Roberts, the U.S. Supreme Court reaffirmed the “straightforward rule … against express religious discrimination.” Excluding religious schools from a public benefit program solely because of their religious status, the court said, violates the First Amendment’s free exercise clause.

Roberts had also written the court’s opinion in Trinity Lutheran Church v. Comer, a 2017 case decided by a 7-2 vote, in which the court held that a blanket exclusion of religious schools from a program for assistance in playground equipment was unconstitutional.

Six justices, three concurring and three dissenting, wrote additional opinions.

Justice Clarence Thomas, for example, confronted Montana’s unusual argument that the First Amendment prohibition on an establishment of religion practically required religious discrimination, undermining the free exercise of religion.

The problem, in Thomas’ view, is that the court had long interpreted the establishment clause too broadly. “Until we correct course on that interpretation,” he wrote, “individuals will continue to face needless obstacles in their attempts to vindicate their religious freedom.”

Justice Neil Gorusch also concurred, arguing for a broad interpretation and application of the free exercise clause. “The Constitution forbids laws that prohibit the free exercise of religion. That guarantee protects not just the right to be a religious person, holding beliefs inwardly and secretly; it also protects the right to act on those beliefs outwardly and publicly.”

Justice Stephen Breyer had agreed with the majority in Trinity Lutheran but dissented here. In both cases, he argued against “an overly rigid application of the First Amendment’s religion clauses.” He preferred a “flexible, context-specific approach” in which judges would evaluate factors such as context, consequences, and purposes.

Similarly, Justice Sonia Sotomayor would also allow the government “some room” to single out and exclude even particular religious entities based on undefined “interests embodied in the religion clauses.”

Roberts rejected such alternative approaches, writing that they “would mark a significant departure from our free exercise precedents” and “would afford much freer rein to judges than our current regime.”

This is another decision with a favorable result resting on an unsettled foundation. The Blaine Amendment provisions remain in state constitutions, and the Supreme Court’s confusing establishment clause precedents remain in the casebooks.

Even though by the slimmest of margins, however, the court reaffirmed what most Americans believe, that the Constitution prohibits explicit religious discrimination.