US President Barack Obama has pledged "the best is yet to come", following a decisive re-election victory over Republican challenger Mitt Romney.
After a hard-fought campaign which highlighted America's political divide, Mr Obama pledged, as he did four years ago, to work with his opponents.
Mr Romney echoed that call for unity as he graciously admitted defeat.
Voters also left the Democrats in charge of the Senate and Republicans leading the House of Representatives.
In the electoral college, the state-by-state tally that determines US presidential elections, Mr Obama has won 303 electoral votes to Mr Romney's 206.
'People before politics'
America's first black president sealed victory with a clean sweep of the most important swing states, including Ohio, Virginia and Colorado.
Mr Romney could only snatch Indiana and North Carolina from his rival's 2008 grasp.
The final swing state - Florida - remains too close to call, as absentee ballots are still being counted.
The Democratic incumbent's lead in the national popular vote count was much slimmer - he had 50.3% to 48.1% for Mr Romney.
Thousands of Obama supporters hugged and cheered in the Chicago convention centre where he delivered his victory speech in the early hours of Wednesday.
"We have picked ourselves up, we have fought our way back and we know in our hearts that for the United States of America the best is yet to come," said Mr Obama, 51.
He was returning to the White House "more determined, and more inspired than ever about the work there is to do", he said.
Mr Obama pledged to work with Republican leaders in Congress to reduce the government's budget deficit, fix the tax code and reform the immigration system.
He also offered to meet Mr Romney to discuss how they could work together.
The Republican admitted defeat with a brief speech shortly after midnight on Wednesday in Boston.
"This is a time of great challenges for America, and I pray that the president will be successful in guiding our nation," Mr Romney said.
The 65-year-old former Massachusetts governor urged politicians on both sides to "put the people before the politics".
'Failures or excesses'
But Mr Obama's prospects for his second term will hinge on the his relationship with congressional Republicans and House of Representatives Speaker John Boehner.
On Wednesday, Mr Boehner said he stood ready to work with the president on avoiding the so-called "fiscal cliff" - a package of automatic tax rises and cuts to military and domestic spending due to come into force in the new year.
Mr Boehner said Republicans would be willing to accept additional tax revenue if it came through tax reform and was accompanied by changes to entitlement and benefit programmes.
"Mr President, this is your moment. We're ready to be led, not as Democrats or Republicans, but as Americans," Mr Boehner said. "We want you to succeed."
Earlier, Mitch McConnell, the Republican leader in the Senate, said voters had 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 added.
Mr Obama will also have to contend with Mr Romney's running mate, Paul Ryan, who has confirmed he will remain in Congress as the Republican's budget chairman.
The president faces his first challenge when Congress returns next week to begin dealing with the fiscal cliff.
Economists warn that the measure - set to be triggered in January unless lawmakers can find agreement - could plunge the nation back into a recession.
Mr Obama was re-elected with the highest unemployment rate - at 7.9% - for any incumbent president since the US wartime leader Franklin Roosevelt.
The fragile economy was rated the top issue by about six out of 10 voters in Tuesday's exit polls. But most of them blamed former President George W Bush for the downturn.
Voters also seem to have given Mr Obama credit for his 2009 rescue of the US car industry and for the commando mission that killed Osama Bin Laden in Pakistan last year.
Mr Obama's re-election also safeguards his healthcare reform law, which Mr Romney had pledged to repeal.
In other key ballots:
- Referendums in Maine, Maryland and Washington state approved same-sex marriage, while a measure in Minnesota to block gay unions failed
- Colorado and Washington state voted to legalise recreational use of marijuana
- California voters rejected a proposal to abolish the death penalty
- In a referendum, Puerto Ricans voted in favour of becoming the 51st US state, if Congress approves the move.
Also on Tuesday's ballot were 11 state governorships, a third of the seats in the 100-member US Senate and all 435 seats in the House of Representatives.
Mr Obama and Mr Romney, as well as their respective allies, raised more than $2bn (£1.25bn) - largely for adverts in swing states.
Preliminary figures suggest fewer people voted than four years ago.
With most ballots tallied, more than 117 million people participated, compared to record-breaking figures of 131 million four years ago.
Turn-out was down sharply in some states, including Texas, as well as states on the US East Coast that were hit hard by super-storm Sandy last week.
International leaders congratulated the president, including Israeli Prime Minister Benjamin Netanyahu, who vowed to work with Mr Obama "to ensure the interests that are vital for the security of Israel's citizens".