US President Obama: "There will be difficult days ahead"
US President Barack Obama says US troops have withdrawn from Iraq's towns and cities on schedule, but he warned of "difficult days" ahead.
Mr Obama described Tuesday's handover to Iraqis as a milestone, but said the country's leaders would face "hard choices" on politics and security.
As Iraqis celebrated the US withdrawal, a car bomb in the northern city of Kirkuk killed at least 27 people.
In the past two weeks about 250 people have been killed in a wave of attacks.
Iraqi and US troops have been on alert for attacks during the pullback.
As Iraq marked the handover with a public holiday called National Sovereignty Day, President Obama said: "Iraq's future is in the hands of its own people."
"The Iraqi people are rightly treating this as a cause for celebration.
"The future belongs to those who build, not to those who destroy."
Mr Obama predicted there would be more violence, like the "senseless bombing" in Kirkuk.
That came 10 days after a truck bomb killed more than 70 in the city's deadliest attack in over a year.
"Make no mistake, there will be difficult days ahead," he said.
He added: "There are those who will test Iraq's security forces and the resolve of the Iraqi people through more sectarian bombings and the murder of innocent civilians.
"I am confident that those forces will fail. Today's transition is further proof that those who have tried to pull Iraq into the abyss of disunion and civil war are on the wrong side of history."
Kirkuk, about 250km (155 miles) from Baghdad, was also the scene of two suicide bombings last month, in which 14 people were killed.
The city is the centre of northern Iraq's oil industry, and home to a volatile mix of Kurds, Arabs, Christians and members of the Turkmen community.
Most of the other bombs that have killed around 250 people in the past fortnight have been aimed at Shia areas.
Despite their pullback from cities and towns, US troops will still be embedded with Iraqi forces.
On Monday, four US soldiers were killed in combat in Baghdad.
The pullback comes two years after the US "surge" of extra troops between February and June 2007, which saw US troop levels in Iraq reach about 170,000.
US-led combat operations are due to end by September 2010, with all troops gone from Iraq by the end of 2011.
Some 131,000 US troops remain in Iraq, including 12 combat brigades, and the total is not expected to drop below 128,000 until after the Iraqi national election in January.