World leaders hailed Barack Obama's triumph in the US presidential election as the start of a new era, while calling for the global superpower to change the way it does business.
Obama parties were staged in capitals around the world. A national holiday was declared in Kenya - where Mr Obama's father was born - to welcome the first black American president.
But in a reminder of the global rivalries that Mr Obama will have to confront, within hours of his victory speech Russian President Dmitry Medvedev announced that Russian short-range missiles would be aimed at a US missile shield in Europe.
Nothing, however, could stop the wave of optimism that spread out from the United States after Mr Obama's victory over Republican rival John McCain on Tuesday. He will be inaugurated on 20 January, with vice president-elect Joe Biden.
New Zealand Prime Minister Helen Clark said Mr Obama is taking office at a critical juncture, with many pressing challenges facing the international community, including the global financial crisis and global warming.
Miss Clark said she would look forward to working with the Obama administration if her Labour Party wins a fourth term in government in Saturday's general election.
National Party leader John Key said if he becomes prime minister, he would anticipate having a strong working relationship with Mr Obama.
The Maori Party says the world has witnessed history. Co-leader Pita Sharples says Mr Obama represents not only the strength of black liberation, but an impressive commitment to the power of the people.
Australian Prime Minister Kevin Rudd said Mr Obama has realised civil rights leader Martin Luther King's dream.
"Forty-five years ago Martin Luther King had a dream of an America where men and women would be judged not on the colour of their skin but on the content of their character. Today, what America has done is turn that dream into a reality."
Mr Rudd said the US election result was a great testament to the strength and maturity of the American democratic process.
Mandela letter to Obama
South Africa's iconic first black leader Nelson Mandela said Mr Obama had shown that anyone could change the world.
Mr Mandela led South Africa's first democratic government from 1994 to 1999 after being imprisoned by apartheid's white minority rule for 27 years.
"Your victory has demonstrated that no person anywhere in the world should not dare to dream of wanting to change the world for a better place," he wrote in a letter to Mr Obama.
In Britain, Prime Minister Gordon Brown said he looked forward to working with Mr Obama, saying the Democratic senator ran an "inspirational campaign, energising politics with his progressive values and his vision for the future".
French president Nicholas Sarkozy described the result as a sign of change and optimism. "At a time when we must face huge challenges together, (Mr Obama's) election has raised enormous hope in France, in Europe and beyond."
Hope for peace
Afghanistan president Hamid Karzai said he applauded the American people for their "great decision" and that it heralded a new era.
"I hope that this new administration in the United States of America, and the fact of the massive show of concern for human beings and lack of interest in race and colour while electing the president, will go a long way in bringing the same values to the rest of world sooner or later."
Mr Karzai hoped it will bring "peace to Afghanistan, life to Afghanistan and prosperity to the Afghan people and to the rest of the world."
China talked of taking its relationship with the US a new level, while Japan's Taro Aso pledged to also strengthen its alliance and "work towards resolving global issues such as the world economy, terror and the environment."
Russian president Dmitry Medvedev said in his first state of the nation speech that the Kremlin hopes "that our partners, the new US administration, will make the choice for fully-fledged relations with Russia".
Mr Obama's election would not lead to a quick US disengagement from Iraq, the country's Foreign Minister, Hoshyar Zebari, said. "A great deal is at stake."
Outgoing Israeli Prime Minister Ehud Olmert said he was certain US-Israeli ties would strengthen under the Obama administration.