WASHINGTON (AFP) – US President Barack Obama said Friday that a deal with his Republican foes on deep government spending cuts was "within reach," as lawmakers groped in private for a compromise by an April 8 deadline.

"Now, there's still details and differences to work out," he said a speech in Landover, Maryland, to employees of global shipping giant UPS. "Both sides are close, though. And we know that a compromise is within reach."

Obama warned that the fragile US economic recovery was at risk if Republicans and his Democrats failed to agree by midnight April 8 on a measure to fund the US government to October 1, triggering a partial shutdown of federal agencies.

"That could jeopardize the economic recovery. It has an impact on everybody's bottom line," said the president, whose 2012 reelection hopes hinge partly on bringing down stubbornly high US unemployment.

Obama noted that Republicans, who used their House of Representatives majority to pass a bill that slashes some $61 billion in spending, and the Democratic-led Senate would have to compromise.

"It would be the height of irresponsibility to halt our economic momentum because of the same old Washington politics," said the president.

His comments came as Republican House Speaker John Boehner delivered essentially the same warning about a possible government shutdown but took issues with Democratic claims that the two sides had agreed to cut $33 billion and were now negotiating over the source of the reductions.

"There is no number. There is no agreement on a number, were going to fight for the largest spending cuts that we can get," he told reporters, urging Senate Democrats to "get serious" about cutting spending.

Boehner said he hoped to reach a deal quickly, declared his office was not preparing for a possible government closure -- which could have vast political repercussions -- and stressed that a shutdown would hurt the economy.

"Frankly, listen, I'll be honest with you, shut the government down, it'll end up costing more than you save," he said.