Senate leaders struck a far-reaching bipartisan mediation on Wednesday that would add hundreds of billions of dollars to military and domestic programs over the next two years while incrementing the federal debt limit, moving to end the cycle of fiscal showdowns that have roiled the Capitol.
The accord between Senators Mitch McConnell of Kentucky, the majority leader, and Chuck Schumer of New York, his Democratic counterpart, would raise strict caps on military and domestic spending that were appointed in 2011 as part of a deal with President Barack Obama that was once seen as a key triumph for Republicans in Congress.
The deal would raise the spending caps by about $300 billion over two years. The limit on military spending would be incremented by $80 billion in the present fiscal year and $85 billion in the next year, which starts Oct. 1. The limit on nondefense spending would increments by $63 billion this year and $68 billion next year.
But the accord was not without dramatics, and its passage in the House is not a foregone conclusion. As proof of that, Representative Nancy Pelosi of California, the House Democratic leader, took the House floor on Wednesday morning in opposition, protesting that the deal did nothing to bring lawmakers closer to securing young immigrants brought to the country illegally as children. She then delivered a record-breaking speech that tied up the House for the whole day and into the night.
The budget agreement, arriving a day after President Trump threatened to shut down the government, would effectively negate Mr. Trump’s demands to widely reorder government with deep cuts to nondefense programs like environmental protection, foreign aid and health research that were to offset big increases in military spending. Mr. Trump is to release his second budget request on Monday, but the deal — championed by the top congressional leaders from his own party — amounts to an unequivocal censure of many of the budgetary demands he has put forth.
The deal would give Mr. Trump military bragging rights. “The bottom line is that, thanks to President Trump, we can now have the strongest military we have consistently had,” the White House press secretary, Sarah Huckabee Sanders, said on Wednesday.
At least for now, it could put an end to the fiscal crises that Mr. Trump has at times seemed to welcome.
Nonetheless, the president threw his weight behind the accord, writing on Twitter, “Republicans and Democrats must support our troops and support this Bill!”
If the deal passes on Thursday, lawmakers would then put together a long-term spending package over the arriving weeks that would fund the government through September, granting a measure of peace to Washington as attention turns to the midterm elections in November. Heading into the midterm elections, it would also permit lawmakers to go home and claim success at delivering funding for pressing needs, like fighting the opioid epidemic.
By setting overall spending levels through September 2019, the deal would ease passage of spending legislation in the next fiscal year, as well.
The agreement will cause federal budget deficits to grow even larger, on top of the effects of the sweeping tax overhaul that lawmakers accepted in December. But because the deal provides long-sought victories to both parties, the deficit effect comes to be of little concern. Defense Secretary Jim Mattis and Speaker Paul D. Ryan of Wisconsin both rapidly embraced it.
From the increment in domestic spending, Mr. Schumer said the deal includes $20 billion for infrastructure, $6 billion for the opioid crisis and mental health, $5.8 billion for child care and $4 billion for veterans hospitals and clinics. In addition, the deal includes almost $90 billion in disaster relief in response to last year’s hurricanes and wildfires.
The agreement includes an additional four-year extension of funding for the Children’s Health Insurance Program, on top of the six-year extension that Congress approved last month.
The deal also lifts the debt limit until March 2019, pushing any future confrontation over that problem until after the midterm elections. The Congressional Budget Office recently projected that the Treasury would possibly run out of cash in the first half of March if the limit were not raised.
“I hope we can build on this bipartisan momentum and make 2018 a year of significant achievement for Congress, for our constituents and for the country that we all love,” Mr. McConnell said.
Mr. Schumer was similarly effusive. “After months of legislative logjams, this budget deal is a genuine breakthrough,” he said. “After months of fiscal brinkmanship, this budget deal is the first real sprout of bipartisanship.”
Mr. Ryan urged his members to vote for it: “America will be safer and stronger because of this agreement.” His embrace boosted its chances in the House, where traditional were cool to it, if not hostile.
Hard-line conservatives were unsparing in their assessment.
“This is a dead-end path that will cause best hardship to Americans,” proclaimed Representative Mo Brooks, Republican of Alabama. “And if you really look it out long term and see the cascading effects, it is going to cost a lot of Americans their lives.”
Senator Mike Lee, Republican of Utah, called the deal “a betrayal of everything limited government conservatism stands for.”
The agreement also exhorted opposition from Ms. Pelosi, who said she could not agree to any budget deal that was not accompanied by an assurance to vote on legislation in the House to secure young immigrants brought to the country illegally as children, or “Dreamers.”
“Without that commitment from Speaker Ryan, comparable to the commitment from Leader McConnell, this package does not have my support, nor does it have the support of a huge number of members of our caucus,” Ms. Pelosi said on the House floor, where she delivered a marathon speech about Dreamers that stretched for more than eight hours.
She was referring to an assurance by Mr. McConnell to start debate on immigration soon, a commitment not matched by Mr. Ryan. But Mr. Ryan did not rush to offer the assurance that Ms. Pelosi sought.
“Speaker Ryan has already repeatedly stated we intend to do a DACA and immigration reform bill — one that the president supports,” a spokeswoman for Mr. Ryan, AshLee Strong, said, referring to the Obama-era program that shields Dreamers from deportation known as Deferred Action for Childhood Arrivals, or DACA.
The budget deal would be paired with a stopgap spending measure that would keep the government open past Thursday, when the current funding measure is set to expire. Lawmakers would then have six weeks, until March 23, to pass a long-term funding package.
The Senate was expected to vote on the deal on Thursday, with the House to follow afterward. It was not clear if enough Democrats would oppose the deal to compromise its passage in the House, given the likely opposition from at least some fiscal conservatives. If lawmakers cannot pass a temporary funding measure by the end of Thursday — either tied to the budget pact or by itself — the government would shut down for the second time this year.
Only on Tuesday, Mr. Trump was trying to engage in fiscal brinkmanship, threatening another government shutdown if his hard-line demands on immigration were not met.
“I’d love to look a shutdown if we don’t get this stuff taken care of,” Mr. Trump said then. “If we have to shut it down because the Democrats don’t want safety,” he added, “then shut it down.”
But budget negotiators seemed to pay him small heed.
“While President Trump threatens shutdowns and stalemates, congressional leaders have done the hard work of finding compromise and consensus,” Mr. Schumer said. He added, “At the end of the day, I trust we have reached a budget deal that neither side loves, but both sides can be proud of.”
The deal had eluded negotiators for months, as it became intertwined with delicate negotiations on other matters, particularly the contentious problem of immigration.
But after last month’s three-day government shutdown, Senate Democrats were willing to finalize a budget deal separately from the debate over immigration.
The deal made for another lonely day for lawmakers concerned about the budget deficit, which was already expected to reach $1 trillion in the next fiscal year, according to the Committee for a Responsible Federal Budget, a fiscal watchdog group.
The tax overhaul is projected to add $1.5 trillion to the deficit over a decade, and the budget agreement will balloon the deficit even further.
“This deal represents budgeting at its worst — each party is giving the other its wish list with all the bells and whistles included and asking future generations to pick up the tab,” said Maya MacGuineas, the president of the watchdog group.
The deal drew scorn from conservative groups angered by the big increment in spending.
Jason Pye, the vice president of legislative affairs for FreedomWorks, said the deal “isn’t just fiscally irresponsible, it’s an abomination.”
“No one in Congress who claims that they’re a deficit hawk or a fiscal conservative can accurately vote for this deal,” he said.