TRENTON, N.J. — New Jersey Gov. Chris Christie said Friday he is pulling out of a nearly 4-decade-old income tax agreement with Pennsylvania, all but ensuring that thousands of residents in each state will see their tax burdens go up.

The Republican governor said his hand was forced because the Democrat-led Legislature failed to find $250 million in health insurance savings for public workers despite assuming the savings in the budget. He said he will reconsider ending the agreement if lawmakers deliver the savings.

“I am left with the least painful option I have to fulfill my constitutional duty to balance the budget for New Jersey taxpayers,” Christie said in a statement.

The 1977 reciprocity agreement allows residents who work in either state to pay income taxes at their home state’s rate. Either governor can pull out of the deal at the start of the year but must give 120 days’ notice.

The deadline for notice this year was Friday.

A spokesman for Democratic Pennsylvania Gov. Tom Wolf said that Christie “erred significantly” and that his action punishes Pennsylvanians.

“It seems that Governor Christie is committed to making Pennsylvania and our residents working in New Jersey suffer the consequences of his failure to enact a responsible budget,” spokesman Jeffrey Sheridan said in a statement.

With the agreement ending, the tax consequences will hurt high-earning Pennsylvanians who work in New Jersey and low-income New Jerseyans who work in Pennsylvania.

Pennsylvania has a flat 3.07 percent income tax rate; New Jersey has a more progressive tax structure, with rates from 5.53 percent to 8.97 percent on income from $40,000 and above.

By way of explanation, Pennsylvania and New Jersey lawmakers and Tax Foundation state director Scott Drenkard provided these scenarios: A Pennsylvania resident who works in New Jersey and makes over $40,000 files a return in Pennsylvania, pays her taxes, then files a return with New Jersey. If taxed at 5.53 percent in New Jersey, she would owe that amount minus credit for her tax payment to Pennsylvania.

Likewise, a low-income New Jersey resident would file at home, then with Pennsylvania. Since New Jersey’s rates are lower than Pennsylvania’s at 1.75 percent for income from $20,000 to $35,000, the taxpayer would get a credit for taxes paid at home but then pay some fraction to Pennsylvania.

Democratic New Jersey Senate President Steve Sweeney said Christie is burdening New Jersey residents and called on him to renegotiate.

“This is the wrong decision for our state,” he said. “This is not the last word on this issue. We should not be balancing New Jersey’s books on the backs of middle-class taxpayers.”

Democratic New Jersey Assembly Speaker Vincent Prieto said Christie shouldn’t blame the Legislature for his failure to cut $250 million.

It’s not the first time a New Jersey governor considered ending the deal. Democrat Jim McGreevey made the same proposal in 2002 but drew criticism from New Jersey lawmakers who represent workers in southern New Jersey.

According to census data from 2010, about 40,000 Camden County, New Jersey, residents commute to Pennsylvania for work, along with more than 20,000 commuters in Burlington and Gloucester counties. The data also show that about 34,000 Bucks County, Pennsylvania, residents work in New Jersey, along with roughly 17,000 from Philadelphia who commute east.

Before Christie’s decision, Scott Drenkard, director of state projects for the nonpartisan Tax Foundation, called the possibility of losing the reciprocity agreement a loss for tax simplicity.

“This is absolutely a money grab,” he said.