The House on Wednesday passed the "No Budget, No Pay Act," a Republican bill that would effectively defuse the debt ceiling threat for several months.

The bill would let the Treasury Department borrow new money until mid-May. In exchange, the legislation would require lawmakers in both chambers of Congress to pass a budget resolution or have their pay withheld until they do.

The vote was 285 to 144. The bill passed largely on the back of GOP support -- 199 Republicans voted for it. But Democrats were needed, and 86 backed the measure.

Most House Democrats, however, voted against the bill. Minority Leader Nancy Pelosi called the salary provision a "joke" and Minority Whip Steny Hoyer called the bill a "political gimmick" that perpetuates uncertainty.

But other leading Democrats said they would support the legislation because it takes the immediate threat of default off the table and divorces the debt ceiling from Republican demands for spending cuts.

Senate Majority Leader Harry Reid said the Senate would "seek to pass" the House bill.

President Obama will not oppose the bill if it reaches his desk, even though he would prefer a longer term debt ceiling increase, the White House said Tuesday.

On CNN.com: House GOP wants to balance budget in 10 years

House Republicans have said for the past two years that they would not raise the debt ceiling unless the increase is matched by a comparable amount of spending cuts. But the bill passed on Wednesday notably doesn't include that quid pro quo.

Here's how the bill would work:

The proposal would suspend the debt ceiling until May 18. And Treasury could continue to borrow for payments that have to be made during the suspension period and nothing else. "In short, no funny stuff," Donald Marron, a former Congressional Budget Office, noted in his blog.

The debt ceiling would then be restored at its current level of $16.394 trillion plus however much Treasury borrowed during the suspension period.

Related: Debt ceiling FAQs

After May 18, Treasury likely could again use "extraordinary measures" to stave off the prospect of default for awhile, giving Congress extra time to raise the debt ceiling. The Bipartisan Policy Center estimates that if the House bill is enacted by the end of January, Treasury could have "sufficient funds to meet all federal financial obligations through at least the end of July."

The bill would also open a path to a longer term increase: It would require the House and Senate to each agree by April 15 to a budget resolution for fiscal year 2014. And such a measure, which is intended to set spending and revenue levels for the next five to ten years, can include debt ceiling increases, said Pete Davis, a former Hill budget staffer who now runs Davis Capital Investment Ideas.

If the House and Senate don't meet the April 15 deadline, lawmakers' pay would be withheld until they pass a budget resolution or until the current Congress ends in January 2015, whichever comes first.

So it's not that lawmakers won't get paid if they miss the deadline. Their salaries would be held in escrow and paid out at some point later.

It's also noteworthy that the bill doesn't actually require Congress to enact a budget, just that each chamber pass a budget resolution, Marron noted.

House Republicans, in coming up with the temporary debt ceiling solution, are in essence conceding that the debt ceiling fight is not their best shot at securing spending cuts and substantive deficit reduction.

Two make-or-break opportunities loom for negotiations over the budget. Unless Congress act by March, the pending sequester would trigger close to $1 trillion in defense and non-defense spending cuts that no one in Congress likes.

The sequester will "go into effect ... unless there are cuts [and] reforms that get us on a plan to balance the budget over the next ten years. It's as simple as that," said House Speaker John Boehner.

And if lawmakers fail to act by March 27, federal funding will expire entirely and the government would be shut down until lawmakers can find some way to agree on spending and taxes for the next year or at least another few months.

- CNN's Ted Barrett and Deirdre Walsh contributed to this report.