Americans chose to stick with a divided government in Washington, however, by leaving the US Congress as it is, with Obama's fellow Democrats controlling the Senate and Republicans keeping the House of Representatives.
After a long, bitter and expensive campaign, the 51-year-old Obama began trying to bring Americans together in a victory speech before thousands of cheering supporters in Chicago. Accused by Romney throughout the campaign of taking a partisan tone, Obama vowed to reach out to Republicans in his new, four-year term.
"You voted for action, not politics as usual," Obama said, calling for compromise and pledging to work with leaders of both parties to reduce the deficit, to reform the tax code and immigration laws, and to cut dependence on foreign oil.
The nationwide popular vote remained extremely close with Obama taking about 50% to 49% for Romney after a campaign in which the candidates and their party allies spent a combined $2-billion. But Obama comfortably won the electoral votes needed in the state-by-state system used to choose US presidents.
Obama scored impressive victories across the country, so much so that the big build-up over Ohio, Virginia and Florida fizzled. Obama reached the 270 electoral votes needed for election even without those three states, rolling up wins in Democratic strongholds and carrying Nevada, Iowa and Colorado.
In the end, he also won Ohio and Virginia and was ahead in Florida, where votes were still being counted.
Romney, the multimillionaire former private equity executive, came back from a series of campaign stumbles to make it close after besting the president in the first of three presidential debates.
The 65-year-old former Massachusetts governor conceded in a gracious speech delivered to disappointed supporters at the Boston convention centre.
"This is a time of great challenge for our nation," Romney told the crowd. "I pray that the president will be successful in guiding our nation."
He warned against partisan bickering and urged politicians on both sides to "put the people before the politics".
Obama told his crowd he hoped to sit down with Romney in the weeks ahead and examine ways to meet the challenges ahead.
The same problems that dogged Obama in his first term are still there to confront him again. He faces a difficult task of tackling $1-trillion annual deficits, reducing a $16-trillion national debt, overhauling expensive social programmes and dealing with a gridlocked Congress that kept the same partisan makeup.
Failures or excess
Senate Republican leader Mitch McConnell did not sound like he was willing to concede his conservative principles, in a sign of potential confrontations ahead.
"The voters have not endorsed the failures or excesses of the president's first term, they have simply given him more time to finish the job they asked him to do together with a Congress that restored balance to Washington after two years of one-party control," McConnell said.
The result eliminates the prospect of wholesale repeal of Obama's 2010 healthcare reform law but it still leaves questions about how much of his signature domestic policy achievement will be implemented.
The immediate focus for the president and Congress will be to confront the "fiscal cliff", a mix of tax increases and spending cuts due to extract some $600-billion from the economy barring a deal with Congress.
Obama, America's first black president, won a new term by convincing voters to stick with him as he tries to reignite strong economic growth and recover from the worst recession since the Great Depression of the 1930s. An uneven recovery has been showing some signs of strength but the country's 7.9% jobless rate remains stubbornly high.
US stock futures slipped, the dollar fell and benchmark treasuries rose after Obama's victory, which investors took to mean no dramatic shift in US economic policy.
Markets had generally expected Obama to win, with the general view that a victory for the Democrat would favour bonds, as he is perceived to favor low interest rates, while Republican challenger Mitt Romney was broadly seen as more business-friendly and supportive for equities.
Obama declares victory on Twitter
Obama beat Romney after a relentless get-out-the-vote push on Twitter, Facebook, Reddit and other platforms.
"This happened because of you. Thank you," he tweeted to 22-million followers just minutes after the first US network called his victory, in an indication of the importance he attached to social networks in his 2012 campaign.
"Four more years," he said straight afterwards, posting a photo of himself hugging First Lady Michelle Obama as other TV networks followed suit and, one-by-one, announced his re-election as 44th President of the US.
The post was his most re-tweeted – with over 600 000 shares – according to Twitter's government and politics account @gov. Popular website BuzzFeed said it was also the most popular ever, overtaking a message from singer Justin Bieber.
The same picture of a relieved and happy-looking Obama hugging his wife appeared on the president's Facebook account – and was shared tens of thousands of times by some of his 32-million fans.
"We did it, we voted for you, now please dear president Obama do what you said you will do, make us proud: Education, Health Care, Green Energy for USA!," Angela De Jesus said under the photo, one of 80 000 comments.
Social networks have emerged as key tools in the months-long US presidential campaign, with both Obama and Romney staging major pushes on these popular platforms to draw in supporters and get them to go out and vote.
"We know in our hearts that for the United States of America the best is yet to come… Whether I earned your vote or not, I have listened to you. I have learned from you. You've made me a better president." – Obama delivers a victory speech to supporters.
"This election is over, but our principles endure… His supporters and his campaign also deserve congratulations. I wish all of them well but particularly the president, the first lady and their daughters." – Republican challenger Mitt Romney concedes defeat.
"I'm just saying it's premature." – Fox News commentator and Republican strategist Karl Rove objects when his own network calls Ohio, and therefore in effect the race, for Obama
"It's not a traditional America anymore. And there are 50% of the voting public who want stuff. They want things.
"Whereby 20 years ago President Obama would have been roundly defeated by an establishment candidate like Mitt Romney, the white establishment is now the minority." – Fox News anchor Bill O'Reilly plays the race card.
"The prime minister congratulates the president of the United States for his victory in the election. The strategic alliance between Israel and the United States is stronger than ever." – Israeli Prime Minister Benjamin Netanyahu, a close friend of Romney.
"I think anybody who's running for office would be lying if they say that there's not some butterflies before the polls come in because anything can happen." – Obama admits to some polling day nerves.
"I just finished writing a victory speech. It's about 1 118 words, and I'm sure it will change before I finish because I haven't passed it around to my family and friends and advisers to get their reaction." – A confident Romney gets ready for his big moment, hours before defeat.
"I bought myself a new mustache comb, because I know I'm gonna be needing it." – Obama campaign senior advisor David Axelrod tells MSNBC he is confident of keeping his trademark mustache after agreeing to shave it off if his boss loses any of the Democratic-leaning states of Pennsylvania, Michigan or Minnesota.
"I was just trying to read [the ballot paper] and breathe, read and breathe. That's what I kept telling myself: 'Read and breathe, read and breathe'." – First-time Chicago voter Galacia Malone (21) describes how she cast her ballot while in labour. She later gave birth to a baby girl.
"If a play were opening tonight, I think the title should be The Ass-Whuppin' Cometh." – Veteran Democratic strategist James Carville is right on the money as he forecasts a thumping Obama win.
"Despite all the hardship we've been through, despite all the frustrations of Washington, I've never been more hopeful about our future. I have never been more hopeful about America." – Obama again, in his victory speech. – AFP & Reuters