But on Monday, a Federal District Court judge in Manhattan rejected that argument.

“The court recognizes that the SALT cap is in many ways a novelty,” the judge, J. Paul Oetken, wrote in his decision. “But the states have failed to persuade the court that this novelty alone establishes that the SALT cap exceeds Congress’s broad tax power.”

The other states joining in the suit were New Jersey, Connecticut and Maryland.

The cap on state and local tax deductions, which had been unlimited, was one of a handful of provisions intended to offset the cost of trillions of dollars in tax cuts included in the 2017 law. The Joint Committee on Taxation, Congress’s nonpartisan scorekeeper on tax matters, estimated the cap and related provisions would raise close to $700 billion in revenue over 10 years.

Independent analyses have found that even in high-tax states like New York, most residents received at least a modest tax cut under the 2017 law. Other provisions of the law, such as the reduction in marginal tax rates, offset the loss of the deduction for many families.

The state and local tax issue is in some ways an awkward one for Democrats, because they are trying to restore a tax break that primarily benefited relatively high earners. In 2017, before the cap took effect, households earning $200,000 or more accounted for roughly half of the nearly $600 billion in state and local tax payments deducted on federal tax returns.

But Democrats argue that the SALT cap penalizes states with progressive tax policies because it effectively makes state and local taxes more expensive for residents. That could make it harder for states to raise taxes, particularly on wealthy residents, and could increase pressure to cut spending. In their lawsuit, the four states argued that the SALT cap amounted to a coercive effort by the federal government to push certain states to change their tax policies.