In this 2013 photo provided by the Center for Individual Rights, Rebecca Friedrichs, a veteran Orange County, Calif., public school teacher, poses for a portrait. (Greg Schneider/AP)

An evenly divided Supreme Court delivered a major reprieve to organized labor Tuesday in a case that could have affected millions of public-sector workers and dealt a severe blow to the most muscular segment of the union movement.

The justices said they were split on a challenge brought by a group of California teachers who claim their free-speech rights are violated when they are forced to pay dues to the state’s teachers union.

Right-leaning legal groups and some of the court’s conservatives had made a priority of overturning a more than 40-year-old Supreme Court precedent and getting rid of what are known as “agency fees.”

It appeared that was exactly what would happen when the case was argued in January. But Justice Antonin Scalia died a month later, and with him went the chance of a five-member majority.

The plaintiffs in a Supreme Court challenge to organized labor explain their grievances in this video. The Supreme Court, down to eight members with the death of Justice Antonin Scalia, announced that it was deadlocked on their case March 29, 2016. (Mackinac Center for Public Policy)

The case involves only public-employee unions — not those of private workers — but those unions are the strongest segment of an organized-labor movement that is increasingly tied to the Democratic Party. At the same time, Republican governors across the nation have become embroiled in high-profile battles with the public-employee unions in their states.

Conservative groups directly asked the court to overturn the 1977 decision in Abood v. Detroit Board of Education, which favored the unions. That ruling said states could allow public-em­ployee unions to collect fees from nonmembers to cover the costs of workplace negotiations but not to cover the union’s political activities. More than 20 states allow the fees.

During oral arguments, it appeared that the conservative groups would get their wish. Scalia had actually been the best hope for unions beyond the four liberal justices. But his questions seemed to make clear that he sided with the challengers.

When the court is evenly split on a case, it affirms the decision of the appeals court that considered the case. In this case, the U.S. Court of Appeals for the 9th Circuit said it was bound by the Abood decision and turned down the challenge.

The Supreme Court also split on a question about how the fees could be collected.

The court could have called for a rehearing of the issue. But the Republican-led Senate has vowed not to act on President Obama’s nomination of Judge Merrick Garland to replace Scalia, and it is unclear when the court will get a ninth justice.

“With the death of Justice Scalia, this outcome was not unexpected,” said Terry Pell, the president of the Center for Individual Rights, the public-interest law firm that brought the case on behalf of the teachers. He said a non-decision was unacceptable.

“Either compulsory dues are an acceptable exception to the First Amendment or they are not. A full court needs to decide this question, and we expect this case will be reheard when a new justice is confirmed,” Pell said.

Public unions in recent years have lived in fear that the Abood precedent would be overturned. In a 2014 case involving health-care workers in Illinois, four of the court’s conservatives signed onto an opinion from Justice Samuel A. Alito Jr. that called the decades-old decision “questionable on several grounds.”

So although Tuesday’s action did not reaffirm Abood, unions chose to celebrate the outcome as a victory.

“The U.S. Supreme Court today rejected a political ploy to silence public employees like teachers, school-bus drivers, cafeteria workers, higher-education faculty and other educators to work together to shape their profession,” said National Education Association President Lily Eskelsen García.

“In Friedrichs, the court saw through the political attacks on the workplace rights of teachers, educators and other public employees,” she said. “This decision recognizes that stripping public employees of their voices in the workplace is not what our country needs.”

Tuesday’s draw makes clear that the ultimate decision is likely to be made by the court’s new justice. And for both sides, that heightens the importance of the president who makes that nomination.

The case is Friedrichs v. California Teachers Association.