However, despite days of increasingly personal attacks leading up to the debate, the second of three, there were no real fireworks.
Senator McCain's proposal that the government buy up $300bn (£171bn) of bad debt to help people stay in their homes goes some way beyond what has been offered by the recent $700bn bail-out plan agreed by Congress - although it is similar to a housing rescue package agreed by Congress in July.
The Republican candidate said: "Is it expensive? Yes. But we all know, my friends, until we stabilise home values in America, we're never going to start turning around and creating jobs and fixing our economy."
He accused the Democratic candidate of being a liberal on spending, adding: "Nailing down Senator Obama's various tax proposals is like nailing Jell-O to the wall."
Mr Obama countered that the current crisis was the "final verdict on the failed economic policies of the last eight years", pursued by President George W Bush and backed by Mr McCain.
Washington would have to change to prioritise the interests of ordinary Americans and ensure they were able to remain in their homes, he said.
'Wrong on Iraq'
The town hall-style debate, taking place less than a month before the 4 November election, generated intense interest among the public.
The moderator, NBC news presenter Tom Brokaw, picked from questions e-mailed in by more than 6 million members of the public and put forward by a studio audience of about 80 uncommitted voters.
This is a guy who sang 'bomb, bomb, bomb Iran', who called for the annihilation of North Korea
Asked whether the economic crisis would affect the ability of the US to act as a "peacemaker" in the world, Mr Obama said no country could maintain the same military influence while its economy was in decline.
He said the foreign policy approach of the Bush administration, supported by Mr McCain, had made it harder for the US to address overseas conflicts like Darfur because it had lost the support of allies.
The Illinois senator also said the US had made a bad decision going into Iraq when al-Qaeda leader Osama Bin Laden remained at large.
Mr McCain said Mr Obama had been wrong to oppose the "surge" policy of sending extra troops to Iraq and accused him of lacking the knowledge and judgement to be commander-in-chief.
On Russia, Mr McCain argued that Mr Obama had been "wrong about Russia when it committed aggression against Georgia".
He also accused Mr Obama of having foolishly said he would carry out a cross-border raid from Afghanistan into Pakistan in pursuit of the Taleban.
Barack Obama on the invasion of Iraq
Quoting former US President Theodore Roosevelt, Mr McCain said the commander-in-chief should "talk softly, but carry a big stick".
However, Mr Obama challenged Mr McCain's claim to exercise sound judgement on foreign policy issues.
"This is a guy who sang 'bomb, bomb, bomb Iran', who called for the annihilation of North Korea - that I don't think is an example of speaking softly," Mr Obama said.
He said the US would never take the military option off the table in dealing with Iran and its nuclear programme, but that Washington must use all the tools at its disposal, including economic sanctions.
It was important for the US to hold direct talks with Iran to deliver a "tough message" that it must change its ways or "face the consequences", he added.
Asked about environmental issues, Mr McCain spoke of having disagreed strongly with the Bush administration over the need to act on global warming and gave his backing to nuclear power.
Mr Obama said investment in developing alternative sources of energy was a matter of national security as well as an environmental priority.
In recent days both camps have launched fresh assaults on the character of their opponent.
The McCain team has focused on Mr Obama's relationship with Bill Ayers, who belonged to a US militant group that opposed the Vietnam War.
The Obama team has highlighted Mr McCain's connections to Arizona tycoon Charles Keating, who was convicted of securities fraud 20 years ago.
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.