Obama praised his counterparts for reaching agreements on Afghanistan, the European missile defense system and how to pool resources in these tough economic times.
He also praised Chicago for its handling of anti-NATO demonstrations during two days of meetings.
"NATO has become a hub of global security. ... We are leaving Chicago with a NATO alliance is stronger and more capable," Obama said at a news conference.
In response to a question from reporters, Obama said everyone recognizes Pakistan has to be part of the solution to Afghanistan and it is in the interests of both countries to root out extremists. Obama acknowledged the tensions that have developed in the U.S. and NATO relationship with Pakistan but he said that's to be expected after 10 years of war. He said he was confident diplomats will be able to work through those tensions.
NATO members agreed to support Afghanistan in an advisory capacity and help train its military after combat forces leave in 2014.
Obama and other NATO leaders said plans are to give Afghan forces combat command by mid-2013, with NATO combat forces leaving by the end of 2014.
"Today we have taken further important steps on the road to a stable and secure Afghanistan and to our goal of preventing Afghanistan from ever again becoming a safe haven for terrorists that threaten Afghanistan, the region, and the world," said a declaration issued by the North Atlantic Council, the principal political decision-making body within NATO.
NATO said it will establish, at the request of Afghanistan, a post-2014 mission to train, advise and assist the Afghanistan military and special forces.
The leaders warned that NATO countries want to see "tangible progress" by the Afghan government regarding its commitments to a democratic society "based on the rule of law and good governance.
"The forthcoming elections must be conducted with full respect for Afghan sovereignty and in accordance with the Afghan Constitution," the declaration said. "Their transparency, inclusivity and credibility will also be of paramount importance. Continued progress towards these goals will encourage NATO nations to further provide their support up to and beyond 2014."
Afghanistan was strongly urged to allow the full participation of Afghan women in the reconstruction, political, peace and reconciliation processes.
Afghan President Hamid Karzai recently announced a third group of provinces is transitioning to Afghan control, which means 75 percent of Afghanistan's population lives in areas led by Afghan forces.
"Today is also an opportunity to ensure our hard-won progress is preserved," Obama said in remarks at the meeting of the International Security Assistance Force. "The Strategic Partnership Agreement that President Karzai and I signed in Kabul ensures that as Afghans stand up they will not stand alone."
The two-day Chicago summit began with non-Afghanistan issues.
The intergovernmental military alliance agreed Sunday to begin using a missile defense system already in place in four European countries, officials said.
Police: Sword-wielding man demanded free tacos
Sign language interpreter at Mandela service called out as fake on Twitter