The Obama administration announced last month via blog post that the president was unilaterally suspending ObamaCare’s employer mandate—notwithstanding the clear command of the law. President Obama’s comments about it on Aug. 9—claiming that “the normal thing [he] would prefer to do” is seek a “change to the law”—then added insult to constitutional injury. It also offers a sharp contrast with a different president who also suspended the law.

On April 27, 1861, President Lincoln unilaterally authorized his commanding general to suspend the writ of habeas corpus so that he could detain dangerous rebels in the early days of the Civil War. Lincoln’s order was constitutionally questionable. The Constitution provides that “The privilege of the Writ of Habeas Corpus shall not be suspended, unless when in Cases of Rebellion or Invasion the public Safety may require it.”

A rebellion was in progress, so suspension was permissible. But the Constitution doesn’t specify who can suspend the writ in such circumstances. Since the Suspension Clause appears in Article I of the Constitution, which is predominantly about the powers of Congress, there is a strong argument that only Congress can suspend the habeas writ.

Lincoln’s order was legally dubious, but what he did next showed remarkable constitutional rectitude. On July 4, 1861, he delivered a solemn message to Congress, in which he did everything possible to square his action with the Constitution. In this message, he set forth the best possible constitutional arguments that he had unilateral power to suspend the writ. These arguments may have been wrong, but they were serious, and they were presented seriously, in good faith.

Lincoln also made a powerful argument about the necessity of his action. Even if he was wrong, and only Congress had the power to suspend the writ, surely the circumstances had to be considered: Congress was in recess and the South was in open rebellion. “The whole of the laws which were required to be faithfully executed, were being resisted, and failing of execution, in nearly one-third of the states,” Lincoln said to Congress.

Should Lincoln have refrained from suspending habeas, if doing so meant that the republic would fall? As he put it: “[A]re all the laws, but one, to go unexecuted, and the government itself go to pieces, lest that one be violated?”

Lincoln also invited Congress to ratify his actions: “Whether there shall be any legislation upon the subject, and, if any, what, is submitted entirely to the better judgment of Congress.” On Aug, 6, 1861, Congress did indeed retroactively ratify “all the acts, proclamations, and orders of the President … respecting the army and navy of the United States.” And later, on March 3, 1863, Congress expressly authorized the president to suspend the writ.

Scholars have debated whether Lincoln exceeded his power by suspending the writ and whether Congress’s retroactive ratification cured any constitutional infirmity. Whatever one’s answer, this is a case of a president—himself a constitutional lawyer—trying, under impossible circumstances, to be as faithful to the Constitution as possible.

Contrast all of this with President Obama’s announcement that he is unilaterally suspending part of the Affordable Care Act. Like Lincoln, Mr. Obama is a constitutional lawyer. And like Lincoln’s action, Mr. Obama’s was a unilateral executive suspension of the law. But in every other way, the president’s behavior could not have been more different from Lincoln’s.

First, Lincoln’s action was at least arguably constitutional, while Mr. Obama’s is not. The Constitution has a provision for suspending habeas. It has no general provision for executive suspension of laws. English kings used to suspend laws, but the Framers rejected that practice: The president “shall take Care that the Laws be faithfully executed.”

Second, Lincoln volunteered an articulate constitutional defense of his action. Mr. Obama seemed annoyed when the New York Times dared to ask him the constitutional question. When the reporter asked whether he had consulted with lawyers about the legality of the mandate’s delay, he declined to answer.

As for Republican congressmen who had the temerity to question his authority, Mr. Obama said only: “I’m not concerned about their opinions—very few of them, by the way, are lawyers, much less constitutional lawyers.” Mr. Obama made no mention of Iowa Sen. Tom Harkin—a Democrat, a lawyer and one of the authors of ObamaCare—who said: “This was the law. How can they change the law?”

Third, Lincoln offered a brilliant and compelling argument about the necessity of his action, given that the republic was in imminent danger. Mr. Obama’s official version of the constitutional-necessity argument was nothing more than a breezy blog post attributed to an assistant secretary for tax policy. The title? “Continuing to Implement the ACA in a Careful, Thoughtful Manner.”

Fourth, and most strikingly, Lincoln promptly looked to Congress to ratify his unilateral action. Congress agreed with Lincoln, and the president welcomed and signed new legislation. President Obama says only that he wishes he could follow the same course. Last week, he said he would like to “simply call up the Speaker” of the House to request a “change to the law” that would achieve his desired delay.

In fact, as the president knows, he doesn’t even need to pick up the phone: On July 17, the House of Representatives passed the Authority for Mandate Delay Act (with 229 Republicans and 35 Democrats voting in favor). This would authorize President Obama’s desired suspension of the law, just as Congress ratified Lincoln’s suspension of habeas corpus.

But unlike Lincoln, President Obama doesn’t welcome this congressional ratification. He has called the House bill that fixes the constitutional problem he created “unnecessary,” and he threatened to veto it. Why? Because the House also passed a companion bill that would delay the individual mandate too. For political reasons, the president doesn’t want to be in the inconvenient position of signing one bill that would give companies a reprieve from ObamaCare, while vetoing another that would grant individuals the same delay. The Democratic-controlled Senate will quietly kill the House bill and save Mr. Obama the awkwardness of having to veto it.

Faced with military exigencies, Lincoln did everything possible to enlist Congress’s support—and thus to follow the Constitution. Mr. Obama, faced with mere political and bureaucratic inconveniences, spurned Congress’s support and flouted the Constitution.