The White House on Monday strongly rejected allegations from Afghan President Hamid Karzai that the United States was colluding with the Taliban to justify the presence of US troops in the country.

"That's categorically false, and nobody believes it," White House spokesman Jay Carney said when asked about Karzai's remarks.

In comments that marred the first visit by the US defense secretary, Chuck Hagel, Karzai charged that Taliban bombings helped the United States argue for a long-term military presence and that Washington was holding "daily" talks with the insurgents behind the backs of his government.

"It is their slogan for 2014, scaring us that if the US is not here, our people will be eliminated," Karzai said on Sunday.

Hagel said he told Karzai that his allegations were incorrect but he played down the president's comments, saying the Afghan leader faced political pressures.

Echoing remarks by the commander of US and NATO troops in Afghanistan, General Joseph Dunford, the White House said Karzai had it all wrong.

"The United States has spent enormous blood and treasure for the past 12 years supporting the Afghan people the effort to ensure stability and security in that country.

"The last thing we would do is support any kind of violence, particularly involving innocent civilians," he said.