UPDATED 10:36 p.m ET
(CBS News) -- President Obama on Tuesday reminded Americans that he has wound down two unpopular wars since taking office more than three years ago and said the defeat of al Qaeda is "within our reach."
"My fellow Americans, we have traveled through more than a decade under the dark cloud of war. Yet here, in the pre-dawn darkness of Afghanistan, we can see the light of a new day on the horizon," Mr. Obama said in a high-profile television address from the war-torn nation.
Obama addresses the nation from Afghanistan
"The Iraq War is over. The number of our troops in harm's way has been cut in half, and more will be coming home soon. We have a clear path to fulfill our mission in Afghanistan, while delivering justice to al Qaeda," Mr. Obama said in the remarks, which lasted about ten minutes.
Mr. Obama arrived in Afghanistan under cover of darkness for an unannounced visit to meet with U.S. troops and to sign a ten-year agreement with President Hamid Karzai on the role of U.S. forces beyond the end of the war in 2014.
Shortly after arriving, about midnight local time, Mr. Obama and Karzai inked a pact to designate Afghanistan a major non-NATO ally. The agreement says the U.S. will provide aid, advisers and support after NATO combat troops leave in 2014.
The visit comes on both the one-year anniversary of the death of Osama bin Laden and the day a new report from the Pentagon giving the war in Afghanistan a mixed review was released.
"The goal that I set - to defeat al Qaeda, and deny it a chance to rebuild - is within our reach," Mr. Obama said, adding that "there will be difficult days ahead. The enormous sacrifices of our men and women are not over."
U.S. military's future in Afghanistan
Issued twice a year to Congress, the Defense Department report said overall insurgent attacks in Afghanistan fell last year for the first drop in five years and praised Afghan forces for their increased security capabilities. At the same time, the Defense Department said corruption remains widespread and violence in the southern region of Kandahar has increased.
There are around 130,000 forces in Afghanistan, including around 90,000 U.S. forces and 40,000 troops from other nations. Those forces are scheduled to end combat operations after 2014, about thirteen years after the war began.
"I recognize that many Americans are tired of war. As president, nothing is more wrenching than signing a letter to a family of the fallen, or looking into the eyes of a child who will grow up without a mother or father," Mr Obama said.
Still, the president vowed not to compromise the earlier efforts as he sought to wind down the war.
"I will not keep Americans in harm's way a single day longer than is absolutely required for our national security. But we must finish the job we started in Afghanistan and end this war responsibly," he said.
The visit is the third trip for Mr. Obama as president, with his most recent time there taking place in late 2010.
National security expert Michael O'Hanlon of the Brookings Institution said he is more encouraged about the prospects for success in Afghanistan after President Obama's speech.
"To see the president emphatically state as a matter of wartime leadership that we are really working closely in a committed way with our Afghan partners I think it was an important message," he said.
"He made it pretty clear that, if he's reelected at least, he'll see the mission past 2014 as important but very limited and very focused," O'Hanlon said.
Obama's surprise trip is sure to draw criticism from Republicans, who have accused Mr. Obama of "spiking the football" in the days leading up to the one year anniversary of the death of bin Laden. However, after the trip, presumptive Republican presidential nominee Mitt Romney struck a somewhat somber tone in a press release.
"I am pleased that President Obama has returned to Afghanistan. Our troops and the American people deserve to hear from our President about what is at stake in this war. Success in Afghanistan is vital to our nation's security. It would be a tragedy for Afghanistan and a strategic setback for America if the Taliban returned to power and once again created a sanctuary for terrorists," Romney said in the release.
"We tolerated such a sanctuary until we lost thousands on September 11, 2001. Many brave Americans have sacrificed everything so that we could win this fight for a more secure future. Let us honor the memory of the fallen, not only by keeping them in our daily thoughts but also by staying true to their commitment," Romney said.
Before the trip, former President Bill Clinton touted Mr. Obama's bold decision to go after bin Laden in a campaign ad that also suggested Romney might not have made the same call.
Romney fired back Tuesday, appearing with former New York City Mayor Rudy Giuliani in front of a New York City firehouse and saying Obama should not be politicizing the issue.
After signing the partnership deal, Obama headed to Bagram air base, where he spoke to U.S. troops.
"The reason America is safe is because of you," Obama told the troops before his speech to the nation.
Tuesday night's remarks also fall on the nine-year anniversary of President George W. Bush's speech aboard the U.S.S. Abraham Lincoln where a sign behind his back declared "Mission Accomplished" for the ship's return to port.
Additional reporting for this piece provided by Rob Mank