Supreme Court Justice Ruth Bader Ginsburg issued an extraordinary apology Thursday, saying she regretted her "ill-advised" comments about Donald Trump and his presidential campaign.
"Judges should avoid commenting on a candidate for public office. In the future I will be more circumspect," she said in a statement issued by the court.
Ginsburg, the court's senior liberal, sought to quickly end an embarrassing flap that had drawn her into a public feud with the Republican candidate for the nation's highest office and had brought her sharp rebukes from critics who accused her of politicizing the court.
In three separate interviews, the 83-year-old justice had said that she despaired for the country if Trump were elected, and she described him as egotistical, inconsistent and a "faker."
She faulted Trump for saying "whatever comes into his head at the moment," but then acknowledged on Thursday that she too had spoken without thinking about the consequences.
Many legal commentators said it was unprecedented for a justice of the high court to speak out against a political candidate during an election year.
"This expression of regret was exactly the right response," said Charles Geyh, an Indiana University law professor who specializes in legal ethics. "Justice Ginsburg is a candid person, and 80% of the time, that's a good thing. But not in this instance. There is a reason we don't want judges involved in politics."
The code of conduct for federal judges says a "judge should refrain from political activity [and] should not … publicly endorse or oppose a candidate for public office." The Supreme Court justices say they follow the code, but are not bound by it.
"It's unfortunate the nine most powerful judges are not subject to the code," Geyh said. "This might put more pressure on them, but I don't see a sign that the Supreme Court justices will be shamed into doing something they don't want to do."
Ginsburg's apology was welcomed by many who had criticized her earlier and were concerned her comments might have a lingering effect.
"Without her apology, I worried that other judges would take sides in political contests by citing the 'Ginsburg defense'. They could say, 'If it's OK for her, it's OK for me.' Now that precedent is erased," said New York University law professor Stephen Gillers.
However, "she can't retract what she said. If there is a case whose outcome decides the presidency, there will be a motion to recuse her. I fear it will be correct, not because she can't decide fairly — I think she would — but because the public won't believe she can. The aim of the recusal law is to ensure public confidence in the integrity of court decisions."
Trump's sharp public rebuke of Ginsburg would only serve to increase the pressure on her to step aside. In one of several tweets, he called her comments "very dumb," adding "her mind is shot — resign!."
Such comments would be seen as evidence she could not rule impartially on an issue affecting him or his campaign.
The controversy over Ginsburg's comments dealt a clear setback to Chief Justice John G. Roberts Jr. and his effort to keep the court separate from the poisonous partisan politics of Washington.
Still, Ginsburg's retraction could serve as a useful warning to judges and justices.
"If there is one thing most judges want to avoid more than bad publicity, it is the embarrassment of a public retraction," said Northwestern University law professor Steven Lubet. "So I think that Justice Ginsburg's expression of regret will definitely influence other judges and justices in the future."
It is rare for Supreme Court justices to issue an apology or express regret for what they have said or done.
In 2004, Justice Antonin Scalia was sharply criticized for refusing to step aside from deciding a case involving Vice President Dick Cheney's energy policy task force.
Scalia had flown to Louisiana with Cheney to go duck hunting a few days after the court agreed to hear the case. But Scalia insisted he had done nothing wrong and could decide the matter impartially. He said later he was proud to have withstood the pressure to withdraw.
But the same spring, Scalia apologized to two reporters after federal marshals seized and erased their tape recordings of a public speech he gave. "The action was not taken at my direction. I was as upset as you were," Scalia said in a letter.
One of the most famous admissions of regret came in 1937, shortly after Justice Hugo Black was confirmed to the Supreme Court. In a national radio address, the former Alabama senator admitted he had been an active member of the Ku Klux Klan in the early 1920s, but said he had quit the organization and wanted no part of it. He went on to serve 34 years and became one of the court's leading advocates of civil rights and civil liberties.
On Twitter: DavidGSavage
2:12 p.m.: The story was updated with information about previous apologies from Supreme Court justices.
1:28 p.m.: This story was updated with additional reaction and background information.