President Donald Trump has suffered a string of court losses in recent days as federal judges ruled that his administration broke the law on a number of matters, including firing officials, shutting down organizations and deporting migrants.

But if the decisions all point in the same direction — Trump and his team have acted lawlessly in egregious ways, judges emphatically said — the real-world consequences may vary.

That is because even assuming all those rulings were to be upheld on appeal, some of Trump’s actions would be easier to undo than others. And the slow pace of litigation means the judiciary is often many steps behind and in some cases unable to catch up.

Still, courts serve as a rare check on Trump, who has steamrolled constraints inside the executive branch, enjoys broad immunity for his official acts because of a 2024 Supreme Court ruling and, as a matter of political reality, has little reason to fear impeachment or even serious oversight inquiries by the Republican-controlled Congress.

The Trump administration has responded, as it often does to court losses, by lobbing insults — calling one such ruling a “rogue judge’s attempt to impede on the separation of powers” and another the act of “an unelected judge with a political ax to grind.” In an interview with New York Times columnist Ross Douthat, Vice President JD Vance declared, “I know this is inflammatory, but I think you are seeing an effort by the courts to quite literally overturn the will of the American people.”

The denunciations make clear that appeals are inevitable, so the story is not yet over.

But among the actions struck down by district court judges this week, the simplest to undo is likely Trump’s dismissal, without cause, of three Democratic-selected members of an independent watchdog agency that scrutinizes counterterrorism policies and actions, the Privacy and Civil Liberties Oversight Board.

On Wednesday, Judge Reggie B. Walton of the U.S. District Court in Washington ruled that Trump had broken the law in doing so and ordered the reinstatement of two members who had sued.

Trump’s move left the board with only one member, largely paralyzing the agency because a quorum of three is necessary for it to act. When its employees wrote up an examination of face scanners in airports this month, they released it as an informal staff report rather than as a statutorily authorized board report that is accompanied by member recommendations and submitted to Congress. They cannot start new investigations.

The administration has not said whether it will appeal, but it has made clear it wants the Supreme Court to expand a president’s authority to fire the leaders of independent agencies. On Thursday, the court permitted Trump, for now, to remove leaders of two other such agencies.

Still, Walton’s reasoning suggested that even if the Supreme Court bolsters Trump’s power to control some of these agencies, the independent structure of the privacy board might survive since it is an investigative body that does not exercise much, if any, “executive power,” like making and enforcing rules. And if the two oversight board members who sued, Travis LeBlanc and Edward Felten, can return to their offices, collect back pay and finish their terms, there will have been relatively little long-term damage done.

A middle ground, in terms of what it would take to undo the administration’s handiwork, is presented by two rulings against Trump this week concerning his efforts to unilaterally shut down parts of the government, or its activities, that were established and funded by Congress.

On Monday, Judge Beryl A. Howell of U.S. District Court in Washington ruled that the administration’s takeover of the U.S. Institute of Peace, a nonprofit think tank that Congress established to seek diplomatic solutions to global conflicts, was unlawful and a “gross usurpation of power.”

She ordered the reinstatement of top officials ousted by the White House and nullified the transfer of the institute’s building to the General Services Administration, which manages the federal real estate portfolio. A separate lawsuit remains pending on behalf of the institute’s workforce. The administration terminated most of the institute’s hundreds of workers in the United States and abroad.

But the Trump administration filed its notice of appeal Wednesday and sought to temporarily block Howell’s order. If there is a stay until the Supreme Court weighs in, even a victory and a similar order to reinstate its broader workforce would not make it straightforward for the institute to simply pick back up.

For one, its former employees may not be willing or able to return. Some may have found other jobs in the interim. For another, Republican lawmakers may decide against allocating funding for it in next year’s budget, in which case Trump’s move, even if lawless, will end up as a mere jump-start.

A ruling Thursday, ordering the Trump administration to halt and reverse Trump’s effort to dismantle the Education Department, raises similar complexities. Judge Myong J. Joun of the U.S. District Court for the District of Massachusetts issued a preliminary injunction ordering officials to reinstate thousands of fired employees.

Joun found that the administration had likely broken multiple laws that require the department to perform various functions, as well as a mandate in the Department of Education Organization Act “that the department itself must exist — not just in name only.”

But the administration has also proposed huge cuts in next year’s budget — meaning that employees considering whether to return may see little long-term future there regardless.

Perhaps the most fraught action against the Trump administration this week came from Judge Brian E. Murphy of the U.S. District Court in Boston. On Wednesday, he declared that the administration had violated an order he issued last month barring the deportation of migrants to countries not their own without first giving them sufficient time to object.

The issue centered on several men who were deported after being told they were being sent to South Sudan, a violence-plagued country in Africa where most of them are not from. The flight apparently landed in the East African nation of Djibouti, where there is a U.S. military base.

Murphy said the Homeland Security Department’s actions had “unquestionably” violated his earlier order, and suggested that he may later find officials in contempt.

But the Republican-dominated Congress is also considering reducing the power of judges to hold people in contempt as part of the budget bill. And now that the deportees are out of the United States, it will be difficult to give them the due process the judge said they were denied.