A deal worked out among top congressional leaders and the White House would enable the U.S. government to keep borrowing money but may cost President Barack Obama critical support among liberal Democrats.

The agreement to immediately raise the government's debt ceiling, and enact already agreed-on spending cuts of about $1-trillion, would avert the financial turmoil that had been feared if Congress failed to raise the $14.3-trillion (U.S.) borrowing limit by Tuesday's deadline. The threat of a U.S. default has effectively been lifted.

And while the deal struck Sunday would spare the President from having to wage another protracted debt-ceiling battle as he campaigns for re-election in 2012, liberal Democrats are livid at him for giving in to Republicans on most other counts.

"Is this the deal I would have preferred? No," Mr. Obama conceded from the White House briefing room as he announced the agreement shortly before 9 p.m.. But he added it "would allow us to avoid default and end the crisis that Washington has imposed on the rest of America."

The pact must first be approved by Congress and party leaders are still scrambling to cobble together enough votes in the Senate and House of Representatives. Congress could authorize a temporary measure allowing the government to pay its bills until final legislation passes both chambers.

"We're not done yet," Mr. Obama said. "I want to urge members of both parties to do the right thing and support this deal."

Under the agreement, a congressional committee would have to come up with a 10-year, $1.5-trillion deficit reduction plan by November. And Mr. Obama could increase the borrowing limit by $2.1-trillion, enough to avoid having to ask Congress for more before the 2012 election.

While the latter point represents a concession by Republicans, the GOP has dictated the terms of this debt-ceiling negotiation almost from the outset. In the past, raising the Treasury's borrowing limit has typically been a routine procedural matter. For the first time, Republicans have succeeded in making it subject to a dollar-for-dollar reduction in the long-term deficit.

"Republicans have achieved a major policy victory without paying any more of a political price for it than Obama himself has paid for looking like he is presiding over a chaotic process," New York University politics professor Patrick Egan said in an interview.

While the deal will not satisfy most Tea Party Republicans, who want to make raising the debt limit contingent on congressional passage of a balanced budget amendment to the Constitution, a bigger risk for Mr. Obama lies in the revolt brewing among House Democrats.

With the defection of some of his hardline caucus members, Republican House Speaker John Boehner will need the support of possibly dozens of Democrats to get the bill through the lower chamber. But many Democrats were already signalling deep dissatisfaction with the agreement.

"This deal trades people's livelihoods for the votes of a few unappeasable right-wing radicals," Democratic congressman Raul Grijalva, co-chair of the Congressional Progressive Caucus, said in a statement.

Automatic cuts in social programs and defence spending would be triggered if a bipartisan committee fails to agree on the components of a $1.5-trillion deficit reduction package, or if its recommendations are rejected by Congress.

This would give both Democrats, who oppose cuts to so-called entitlement programs, and Republicans, who are against cutting the military budget, a strong incentive to come to an agreement on the $1.5-trillion package. But liberal Democrats are upset that tax increases on the wealthy are not included among the automatic triggers if no deal is reached.

"It's another Obama cave-in," American University history professor Allan Lichtman said. "Everyone in every corporate boardroom in America has to be laughing their heads off."

The joint committee of three Democrats and three Republicans charged with coming up with the $1.5-trillion deficit reduction package would not be excluded from considering a reform of the tax code that increases revenues.

And Mr. Obama insisted he would continue to fight for a "balanced approach" to deficit reduction that includes revenue-enhancing tax reform and cost-saving measures in Medicare and Social Security.

But tax increases grow even more unlikely as the election approaches - and not only because Republicans oppose them. Several Senate Democrats in conservative-leaning states are up for re-election in 2012, including Missouri's Claire McCaskill, Nebraska's Ben Nelson, Florida's Bill Nelson, West Virginia's Joe Manchin and Montana's Jon Tester.

Despite the flak Mr. Obama may take from his base over this deal, however, the relief on his face was apparent last night. He neither wanted to be the first President to see the government default on his watch, nor watch the anger of American voters over the impasse in Washington endure.

In a town built on hyperbole, the President ended the night with an understatement: "This process has been messy. And it has taken far too long."