See more of the story

WASHINGTON – A federal judge in Texas struck down the entire Affordable Care Act on Friday on the grounds that its mandate requiring people to buy health insurance is unconstitutional and the rest of the law cannot stand without it.

The ruling was on a lawsuit filed this year by a group of GOP governors and state attorneys general. A group of intervening states led by Democrats promised to appeal the decision, which will most likely not have any immediate effect. But it will almost certainly make its way to the Supreme Court, threatening the survival of the landmark health law and, with it, health coverage for millions of Americans, protections for people with pre-existing conditions and much more.

In his ruling, U.S. District Judge Reed O'Connor said that the individual mandate requiring people to have health insurance "can no longer be sustained as an exercise of Congress' tax power."

Accordingly, O'Connor, a George W. Bush appointee, said that "the individual mandate is unconstitutional" and the remaining provisions of the Affordable Care Act are invalid.

At issue was whether the health law's insurance mandate still compelled people to buy coverage after Congress reduced the penalty to zero dollars as part of the tax overhaul that President Donald Trump signed last December. When the Supreme Court upheld the mandate as constitutional in 2012, it was based on Congress' taxing power. Congress, the court said, could legally impose a tax penalty on people who do not have health insurance.

But in the new case, the plaintiffs argued that with the penalty zeroed out, the individual mandate had become unconstitutional — and that the rest of the law could not be ­severed from it.

The Justice Department's response to the case was highly unusual: though it disagreed with the plaintiffs that the entire law should be struck down, it declined this year to defend not just the individual mandate, but the law's provisions that protect people with pre-existing conditions. That prompted a coalition of 16 states and the District of Columbia, led by California, to intervene and defend the law.

On Friday night, a spokeswoman for California Attorney General Xavier Becerra said California and the other defendant states would challenge the ruling with an appeal in the Fifth U.S. Circuit Court of Appeals.

"Today's ruling is an assault on 133 million Americans with pre-existing conditions, on the 20 million Americans who rely on the ACA's consumer protections for health care, on America's faithful progress toward affordable health care for all Americans," Becerra said. "The ACA has already survived more than 70 unsuccessful repeal attempts and withstood scrutiny in the Supreme Court."

Trump, who has consistently sought the law's repeal and has weakened it through regulatory changes, posted a response to the ruling on Twitter late Friday: "As I predicted all along, Obamacare has been struck down as an UNCONSTITUTIONAL disaster! Now Congress must pass a STRONG law that provides GREAT healthcare and protects pre-existing conditions."

The ruling came on the eve of the deadline for Americans to sign up for coverage in the federal insurance exchange created under the law.

Since the suit was filed in January, many health law specialists have viewed its logic as weak but nevertheless have regarded the case as the greatest looming legal threat to the 2010 law, which has been a GOP whipping post ever since and assailed repeatedly in the courts.

No matter how O'Connor ruled, legal experts have been forecasting that the Texas case would be appealed and could well place the law again before the high court, giving its conservative newest member, Justice Brett Kavenaugh, an opportunity to take part.

The suit was initiated by Texas Attorney General Ken Paxton, who describes himself as a Tea Party conservative, with support from 18 GOP counterparts and a governor. In a court brief and an accompanying letter to congressional leaders, the Justice Department contended that, once the insurance mandate's penalty is gone next month, that will invalidate the ACA's consumer protections, such as its ban on charging more or refusing to cover people with pre-existing medical conditions. But the administration argued that many other parts of the law could be considered legally distinct and thus can continue.

The midterm elections last month have altered the political map in the case. In Wisconsin, an incoming Democratic attorney general, Josh Kaul, campaigned on a promise to withdraw the state from the lawsuit, but Wisconsin's GOP Legislature and outgoing Gov. Scott Walker tried in a lame duck session to block his ability to do that. In Maine, outgoing GOP Gov. Paul LePage joined the lawsuit, but the state Attorney General's Office told the court last month that the governor did not have that power.

The Washington Post contributed to this report.