On the first visit by a French head of state since the US-led war plunged Iraq into years of sectarian slaughter and insurgency, Sarkozy met Iraqi President Jalal Talabani and was due to hold talks with Prime Minister Nuri al-Maliki.
Violence has dropped sharply in Iraq in the past few months and US troops are preparing to pull out of cities and withdraw completely by the end of 2011. In the last two weeks Iraq held the most peaceful elections since the fall of Saddam Hussein.
Iraqi officials believe the time has come for foreign companies to invest, especially in their oil fields which hold the world's third largest proven crude reserves. French oil major Total SA is among firms qualified to bid for long-term development Iraqi oil contracts.
"Security is improving despite the lingering problems. The situation is not perfect, but a few months ago who was betting that I was going to visit Iraq and its leaders?" Sarkozy said during a joint news conference with Talabani, speaking through an Arabic interpreter.
Sarkozy praised Iraq for regaining its sovereignty with a security pact with the United States that sets a final withdrawal date and also for voting enthusiastically and for a wide variety of parties in the January 31 provincial polls.
"The world needs a united, democratic, sovereign and strong Iraq," he said.
France enjoyed relatively close relations with Iraq under Saddam, and former French President Jacques Chirac led international opposition to the 2003 invasion.
Tens of thousands of Iraqis and more than 4,000 US soldiers died in fighting that erupted in the aftermath of the invasion between Iraq's majority Shi'ite Muslims and minority Sunni Arabs who ruled the country under Saddam.
Sarkozy has sought warmer relations with Washington since his election in 2007.
The inauguration in January of President Barack Obama has also ushered in a new tone in international relations and other European countries that opposed the war, such as Germany, are expected to send high-level delegations to Iraq soon.
Obama pledged during the US election campaign to pull out of Iraq within 16 months, faster than foreseen in the bilateral security pact signed by his predecessor, which calls for the last US soldier to leave by the end of 2011.
US military commanders favour a slower pullout that would not put at risk Iraq's recent security gains.
The violence that took Iraq to the brink of all-out civil war has fallen sharply, and the January 31 provincial polls took place without a single major attack being recorded anywhere.
Yet suicide and car bomb attacks remain common and Sarkozy's visit, part of a Middle Eastern tour, was shrouded in secrecy.
"This visit was not announced for reasons of security," the French president's office said.
The last high-level visit by a French official occurred in May 2008 when Foreign Minister Bernard Kouchner, who accompanied Sarkozy on Tuesday, spent a few days in the country, in a sign of what Paris said then was a renewed commitment to Iraq.
A visit to Iraq will play better in French public opinion now that the unpopular former US President George W Bush has left office.
Kouchner, one of the few French politicians who backed military intervention in Iraq, has previously had to apologise to Maliki after being quoted by Newsweek magazine as having called for him to be replaced.