Chief Justice John G. Roberts Jr., under intense scrutiny for his decision upholding President Obama’s health-care law, is headed for an overseas teaching gig in Malta.

“An impregnable island fortress,” Roberts told a conference of judges and lawyers meeting Friday morning in rural Pennsylvania. “It seemed like a good idea.”

Back in Washington, the legal and political worlds are trying to digest the stunning news that one of the court’s most consistent conservatives had pulled Obama’s signature domestic achievement from the brink.

Court specialists analyzed Thursday’s 5-to-4 opinion for clues, wondering whether Roberts might have switched his vote from invalidating the law to upholding it largely unscathed.

Conservatives found new ways to express their anger: Radio host Glenn Beck was offering a $30 T-shirt with Roberts’s face and the word “COWARD” boldly printed in yellow.

And some liberals were making a 24-hour pivot from praising Roberts’s statesmanship to wondering whether the victory for Obama and congressional Democrats was delivered in a Trojan horse.

Roberts gave no further guidance, declining to elaborate on the decision at the conference of the D.C. Circuit.

When Chief U.S. District Judge Royce C. Lamberth asked Roberts whether it ever bothered him that he “can’t respond to criticism,” the chief justice drew laughter when he simply said, “no” and turned to the next question.

In the opinion that stirred this week’s controversy, Roberts wrote that it was the duty of the court to avoid rejecting an act of Congress if there is a plausible reason for saving it. “It is well established that if a statute has two possible meanings, one of which violates the Constitution, courts should adopt the meaning that does not do so,” Roberts wrote.

So he rejected the government’s argument that requiring most Americans to purchase health insurance or pay a penalty was justified under the Constitution’s commerce clause, which gives Congress the power to regulate interstate commerce.

But, joined by the court’s four liberals, he said the penalty operated as a tax, and thus was proper under the taxing clause.

Some wondered whether Roberts originally had joined the court’s four conservatives, pointing to oddities in the opinion. The dissent offered by the conservative justices with whom Roberts usually sides in ideological disputes — Antonin Scalia, Anthony M. Kennedy, Clarence Thomas and Samuel A. Alito Jr. — read more like an opinion for the court that had been abandoned, said David E. Bernstein, a law professor at George Mason University.

The dissent did not engage in a debate with the controlling opinion offered by Roberts, as is usual in Supreme Court judgments. It contained a long section on whether the law can be severed from the individual mandate, unnecessary if a majority had already found the mandate constitutional.

It went to great lengths to establish the reasons the four thought the commerce clause did not offer the powers the Obama administration claimed. It was territory that Roberts already had largely covered in his opinion.

There is nothing improper about a justice changing his or her mind on a case before the decision is delivered. But the insinuation was that Roberts may have been motivated by a desire to spare recriminations from the image of the court’s five justices appointed by Republican presidents overturning a landmark bill passed by congressional Democrats and signed by Obama.

“The political class and legal left conducted an extraordinary campaign to define such a decision as partisan and illegitimate,” said a Wall Street Journal editorial. “If the chief justice capitulated to this pressure, it shows the court can be intimidated and swayed from its constitutional duties.”

Others thought it unlikely that Roberts had changed his mind. “There are some loose ends in the opinions, to be sure, but it might just be because they were pressed for time,” George Washington University law professor Orin Kerr wrote on the Volokh Conspiracy, a Web site on legal issues where much of the speculation found a home.

And it was also clear during the first hour of the lengthy oral arguments that Roberts was exploring the theory he later adopted: that the penalty served as a way to satisfy the government’s requirement, making the mandate less of a command.

“The idea that the mandate is something separate from whether you want to call it a penalty or tax just doesn’t seem to make much sense,” he said during the arguments.

Stanford University constitutional law professor Pamela Karlan said liberals should see the decision as strategic. “Is that man clever or what?” she said, adding that Roberts learned a lesson from his predecessor and mentor William H. Rehnquist about when to look for compromise.

“He knows he’s going to be on the court for years.”

While the decision has the immediate effect of saving the health-care law, Karlan said, the opinion contained what could be important and long-lasting principles. The strict reading of the commerce clause is something conservatives have wanted for years.

And the court said the law’s attempt to force states to expand Medicaid rolls by threatening to withhold federal funds was improperly coercive.

“That truly breaks new ground,” said Richard Fallon, a Harvard law professor. “It’s the first time since the 1930s that the Supreme Court has invalidated a federal spending statute that gives money to states and attaches strings.”

He added: “A number of other federal spending programs that attach strings will now be attacked as coercive.”

At the judicial conference at Nemacolin Woodlands Resort on Friday, Roberts was also getting credit for defusing a potentially partisan outcome in the health-care case.

“When I first saw that it was a 5-4 decision and the chief justice was the deciding vote, I wondered, ‘How did this happen?’ ” said John O’Quinn, a Justice Department lawyer during the Bush administration. “Then I read the opinion and the reasoning behind it and realized it was filled with thoughtful reasoning.”

Lamberth made a similar point: “There is a feeling that people are happy to see the judiciary does not appear to be partisan. After all of the partisan bickering going on, the court’s opinion was based on legal principles.”

If the health-care vote led many to the think that Roberts, finishing his seventh term on the court, has mastered the gears and levers that come with being chief justice, the 57-year-old justice said in his conference speech that there are rule changes that could make his job easier.

For instance: “The odd historical quirk that the chief justice only gets one vote.”