Tonight's encounter (9 p.m. EDT start time) is the first of three for the candidates. By agreement between the rival campaigns, it will focus on the economy and other domestic issues.
Jim Lehrer of PBS drew moderator's duties, with Obama getting the first question and Romney the last word.
The two candidates paid separate visits to the debate hall on the campus of the University of Denver during the day to familiarize themselves with the surroundings.
Five weeks before Election Day, early voting is under way in scattered states and beginning in more every day. Opinion polls show Obama with an advantage nationally and in most if not all of the battleground states where the race is most likely to be decided.
That put particular pressure on Romney to come up with a showing strong enough to alter the course of the campaign.
The sputtering economy served as the debate backdrop, as it has for virtually everything else in the 2012 campaign for the White House. Obama took office in the shadow of an economic crisis but promised a turnaround that hasn't materialized. Economic growth has been sluggish throughout his term, with unemployment above 8 percent since before he took office.
The customary security blended with a festival-like atmosphere in the surrounding area on a warm and sunny day. The Lumineers and Black Eyed Peas frontman will.i.am performed for free, and school officials arranged to show the debate on monitors outside the hall for those without tickets.
There was local political theater, too, including female Romney supporters wearing short shorts and holding signs that said, "What War On Women?" — a rebuttal to claims by Obama and the Democrats.
Both campaigns engaged in a vigorous pre-debate competition to set expectations, each side suggesting the other had built-in advantages.
Romney took part in 19 debates during the campaign for the Republican primary early in the year. The president has not been onstage with a political opponent since his last face-to-face encounter with Arizona Sen. John McCain, his Republican rival in 2008.
Obama and Romney prepared for the evening with lengthy practice sessions. Romney selected Ohio Sen. Rob Portman as a stand-in for the president; Obama turned to Massachusetts Sen. John Kerry to play the Republican role.
The two presidential rivals also are scheduled to debate on Oct. 16 in Hempstead, N.Y., and Oct. 22 in Boca Raton, Fla.
Vice President Joe Biden and Republican Rep. Paul Ryan of Wisconsin have one debate, Oct. 11 in Danville, Ky. Both men have already begun holding practice sessions.