Iraq officially took control of its fate Tuesday as the U.S. pulled its combat troops out of Baghdad and other cities and towns, handing over security responsibilities to Iraqi forces.

The withdrawal completed the Status of Forces agreement signed last November, and touched off celebrations in Baghdad and other cities.

"It is a day when Iraqis celebrate as they continue to move towards exercising their full sovereignty," U.S. Commanding General Ray Odierno told FOX News. "The Iraqi people should be very proud of the dedication, progress, and sacrifice of the Iraqi security forces and the government of Iraq."

Prime Minister Nouri al-Maliki declared Tuesday to be "National Sovereignty Day," complete with a military parade to display to Iraqis — and a still stubborn insurgency — its ability to maintain order in a nation ravaged by six years of war.

"This day, which we consider a national celebration, is an achievement made by all Iraqis," al-Maliki said in a televised speech.

"Our incomplete sovereignty and the presence of foreign troops is the most serious legacy we have inherited (from Saddam). Those who think that Iraqis are unable to defend their country are committing a fatal mistake," he said.

But the dangers facing Iraq were brought into stark focus after a car bomb exploded on Tuesday, killing at least 24 people in the city of Kirkuk. On Monday U.S. military officials reported that four American soldiers were killed in combat on the eve of the withdrawal.

But these violent incidents do not diminish the achievements in Iraq, according to the White House.

"General Odierno's confident in (the Iraqis') ability to move forward. He's said it's not surprising we've seen high-profile incidents in which seek to kill innocent civilians to convince followers that what's happening today is result of their actions, which it's not," said White House Press Secretary Robert Gibbs, who called the U.S. troop removal "a step forward."

Officials said the four soldiers killed on Monday served with the Multi-National Division-Baghdad, but did not provide further details pending notification of their families. The soldiers died as a "result of combat related injuries," officials said.

The withdrawal that was completed late Monday is part of a U.S.-Iraqi security pact and marks the first major step toward withdrawing all American forces from the country by Dec. 31, 2011. President Barack Obama has said all combat troops will be gone by the end of August 2010.

President Jalal Talabani said the day could not have happened without the help of the United States, which invaded Iraq in 2003 with the aim of ousting Saddam Hussein — who was later convicted by an Iraqi court and executed in Dec. 2006.

"While we celebrate this day, we express our thanks and gratitude to our friends in the coalition forces who faced risks and responsibilities and sustained casualties and damage while helping Iraq to get rid from the ugliest dictatorship and during the joint effort to impose security and stability," Talabani said.

Describing June 30 as a "glorious page" in Iraq's history, Talabani warned that "security will not be achieved completely without proper political environment and without a real national unity and reconciliation."

Iraq marked the day with an overnight display of fireworks, while thousands attended a party in a park where singers performed patriotic songs.

The midnight handover to Iraqi forces filled many citizens with pride but also trepidation that government forces are not ready and that violence will rise. Shiites fear more bombings by Sunni militants; Sunnis fear that the Shiite-dominated Iraqi security forces will give them little protection.

If the Iraqis can hold down violence in the coming months, it will show the country is finally on the road to stability. If they fail, it will pose a challenge to Obama's pledge to end a war that has claimed the lives of more than 4,300 U.S. troops and thousands of Iraqis.

Despite Tuesday's formal pullback, some U.S. troops will remain in the cities to train and advise Iraqi forces. U.S. troops will return to the cities only if asked. The U.S. military will continue combat operations in rural areas and near the border, but only with the Iraqi government's permission.

Gen. Odierno told FOX News, "Our combat forces partnering with the Iraqi security forces will secure the belts and borders in an attempt to eliminate safe havens and sanctuaries, and to limit freedom of movement of insurgents and prevent the facilitation of foreign fighters through the borders."

The U.S. has not said how many troops will be in the cities in advisory roles, but the vast majority of the more than 130,000 U.S. forces remaining in the country will be in large bases scattered outside cities.

There have been some worries that the 650,000-member Iraqi military is not ready to maintain stability and deal with a stubborn insurgency.

Privately, many U.S. officers worry the Iraqis will be overwhelmed if violence surges, having relied for years on the Americans for nearly everything.

The Associated Press, Reuters and Time contributed to this report.