The Supreme Court ruled Wednesday for the first time that federal discrimination laws do not protect church employees who perform religious duties, a major church-state decision that recognizes religious groups’ constitutionally protected right to select their own leaders.

The justices ruled unanimously that the First Amendment’s guarantee of the free exercise of religion means that even neutral laws intent on banning workplace discrimination may not be applied to a religious institution choosing “those who will guide it on its way.”

“The interest of society in the enforcement of employment discrimination statutes is undoubtedly important,” Chief Justice John G. Roberts Jr. wrote for the court.

“But so too is the interest of religious groups in choosing who will preach their beliefs, teach their faith, and carry out their mission.” When those principles are in conflict, Roberts said, “the First Amendment has struck the balance for us.”

The ruling came in the case of Cheryl Perich, a teacher who complained that Hosanna-Tabor Evangelical Lutheran Church and School in Redford, Mich., violated the Americans With Disabilities Act in 2005 when it fired her after she received a narcolepsy diagnosis.

The Supreme Court building in Washington, D.C. (Andrew Harrer/BLOOMBERG)

Richard W. Garnett, director of Notre Dame Law School’s Program in Church, State, and Society, said the ruling is the court’s most important decision on religious freedom in decades.

“The government doesn’t get to second-guess religious communities’ decisions about who should be their teachers, leaders and ministers,” he said.

Those who had supported Perich said the decision threatened equal application of the law.

“Blatant discrimination is a social evil we have worked hard to eradicate in the United States,” said the Rev. Barry W. Lynn, executive director of Americans United for Separation of Church and State. “I’m afraid the court’s ruling today will make it harder to combat.”

The justices did not provide a “rigid formula” for determining who is covered by the “ministerial exception” or whether it bars other types of suits.

The Equal Employment Opportunity Commission (EEOC) and the Obama administration had backed Perich’s lawsuit against the religious school.

Perich joined the school as a “lay teacher” in 1999 and then underwent extensive religious training. She became a “called” teacher, expected to perform her job “according to the Word of God and the confessional standards of the Evangelical Lutheran Church as drawn from the Sacred Scriptures.” She became ill in 2004, but said she was ready to return to work in 2005.

The school said that it had hired another teacher and that there was no place for her. When she threatened to sue to get her job back, she was fired for “insubordination and disruptive behavior.” Church and school leaders said her actions violated a doctrine of the Lutheran Church-Missouri Synod that says disputes should be resolved within the church rather than in court.

The U.S. Court of Appeals for the 6th Circuit said Perich did not qualify as a minister because her duties as a called teacher were the same as those of a lay teacher.

Perich sometimes taught religious classes as well as secular classes such as math, and she occasionally led chapel services. She estimated that the “religious” part of her school day was about 45 minutes.

But Roberts said there was little doubt that Perish was a member of the church leadership. She “held herself out as a minister of the Church by accepting the formal call to religious service,” and even claimed a special ministerial housing allowance on her taxes. The determination of ministerial duties “is not one that can be resolved by a stopwatch,” he wrote.

Roberts devoted several pages of his opinion to tracing the development of the Constitution’s religious clauses and their importance to the new nation.

“The Establishment Clause prevents the Government from appointing ministers, and the Free Exercise Clause prevents it from interfering with the freedom of religious groups to select their own,” he wrote.

For that reason, he was particularly dismissive of the government’s argument on Perich’s behalf that her case should be analyzed as though the association in question were a labor union or a social club instead of a church.

“We cannot accept the remarkable view that the Religion Clauses have nothing to say about a religious organization’s freedom to select its own ministers,” he wrote.

Roberts noted that the EEOC and Perich “foresee a parade of horribles” that could result from the court recognizing a ministerial exception to discrimination suits.

At oral arguments, some justices wondered whether church employees might face retaliation for testifying about child abuse, for instance. Roberts said those questions could be addressed if they arose.

“We express no view on whether the exception bars other types of suits, including actions by employees alleging breach of contract or tortious conduct,” he wrote.

Justice Clarence Thomas said in a concurring opinion that he would go beyond the majority’s holding and leave up to the church the definition of who is covered by the exception. Civil courts, he said, should “defer to a religious organization’s good-faith understanding of who qualifies as a minister.”

Justices Samuel A. Alito Jr. and Elena Kagan wrote separately to make clear that they do not think the term “minister” is central to courts determining who is covered by the exemption. Catholics, Jews, Muslims, Hindus and Buddhists rarely use the title, they wrote.

The function performed by the employee is key, Alito wrote.

He said it should apply to anyone “who leads a religious organization, conducts worship services or important religious ceremonies or rituals, or serves as a messenger or teacher of its faith.”

The case is Hosanna-Tabor Evangelical Lutheran Church and School v. EEOC.