"We have also taken into account the simple reality that America can no longer afford to see Iraq in isolation from other priorities: we face the challenge of refocusing on Afghanistan and Pakistan; of relieving the burden on our military; and of rebuilding our struggling economy - and these are challenges that we will meet."
Mr Obama said all US troops would have left Iraq by the end of 2011, in line with an agreement signed between the two countries last year.
And he paid tribute to US forces who have served in Iraq over the past six years.
"Thanks to the sacrifices of those who have served, we have forged hard-earned progress, we are leaving Iraq to its people, and we have begun the work of ending the war."
He also said his administration would increase the numbers of soldiers and Marines, in order to lessen the burden on those now serving, and was committed to expanding veterans' health care.
Addressing the Iraqi people directly, Mr Obama said theirs was "a great nation" that had persevered with resilience through tyranny, terror and sectarian violence.
I asked Robert Gates, the defence secretary, whether he could look the outside world in the eye and say 'America won!'
He went on: "So to the Iraqi people: let me be clear about America's intentions. The United States pursues no claim on your territory or your resources.
"We respect your sovereignty and the tremendous sacrifices you have made for your country. We seek a full transition to Iraqi responsibility for the security of your country."
Mr Obama said that as a result of lessons learned from Iraq, he had ordered a review of US policy in Afghanistan and put the costs of Iraq and Afghanistan into the federal budget.
Stressing that Iraq's future was inseparable from that of the broader Middle East, Mr Obama said the US would now "pursue principled and sustained engagement with all of the nations in the region, and that will include Iran and Syria".
The new US ambassador to Iraq would be Christopher Hill, the former US chief negotiator with North Korea, the president added.
The withdrawal plan is a middle way between the speedy reduction Mr Obama envisaged during his election campaign and the slower one some military leaders may prefer, BBC North America editor Justin Webb says.
US soldiers give their reaction to Obama's withdrawal plans
Mr Obama wants only two combat brigades to leave this year but after December elections in Iraq the pace should quicken, our correspondent says.
The BBC's Mike Sergeant in Baghdad says that security in Iraq is now better and people say they are ready for US forces to leave.
However, some are deeply worried about what exactly will happen when US combat troops disappear, our correspondent says.
While Iraq's security forces are much more capable now, they depend heavily on US back-up for logistics, intelligence and air support, our correspondent says. A great deal of American financial and practical support may be needed for many years.
Democrats have expressed concern that the troop withdrawal is being watered down, with the bulk of troops being left in place until next year.
However, some sceptics have said that a fast withdrawal could reverse the dramatic but fragile gains in security in Iraq.
Senate Majority Leader Harry Reid described Mr Obama's plan as "sound and measured" but said the US "must keep in Iraq only those forces necessary for the security of our remaining troops and the Iraqi people".
House Speaker Nancy Pelosi said the plan was "good news" because it signalled an end to the war, but called for clearly-defined missions for the remaining troops.
Republicans - including Senator John McCain, Mr Obama's former rival for the presidency - broadly supported the plan but suggested Mr Obama should give credit to President George W Bush for the stability brought by his "surge" strategy of pouring extra troops into Iraq.
House Republican Minority Leader John Boehner said Mr Obama had outlined "a responsible approach that retains the flexibility to reconsider troop levels and to respond to changes in the security environment".
REACTION TO BARACK OBAMA'S IRAQ PLAN
President Obama very appropriately and correctly thanked US Marines for precipitating the turnabout in Iraq. But if there is a chance of success in Iraq now as defined by Barack Obama, shouldn't there be some mention of the change in strategy, and the former Commander in Chief, the guy who hung in there?
Several Democratic leaders have voiced strong concerns about the size of the "transition force." What's more, for all of the success in reducing violence in Iraq, long-term political progress remains elusive, and will have to be a high priority for the administration. Still, Obama has outlined the beginning of the end. It's about time.
In 2003, then Maj Gen David Petraeus, commander of the 101st Airborne Division that had participated in the invasion of Iraq, had a running joke with an embedded reporter... The general would turn to the reporter and muse, "Tell me how this ends." Today at Camp Lejeune... President Barack Obama - an antiwar Illinois state senator at the time of the invasion - answered Petraeus.
2011 just became a hard stop, I think. When presidents lay down markers like that, they don't easily walk away from them. It's now what Iraqi politicians described it as: the American Withdrawal of Forces Agreement. I fear Iraqi domestic political convenience just became American strategic reality. This converts the SOFA from a framework for a long-term strategic partnership to a guarantee of withdrawal.
This page is best viewed in an up-to-date web browser with style sheets (CSS) enabled. While you will be able to view the content of this page in your current browser, you will not be able to get the full visual experience. Please consider upgrading your browser software or enabling style sheets (CSS) if you are able to do so.