An election campaign that has constantly defied all predictions ended yesterday with perhaps its biggest shock of all - setting the stage for a President Donald Trump.
The controversial real estate tycoon rode a wave of unhappiness with the status quo to upset former secretary of state Hillary Clinton, and become the first non-politician to be elected president.
The 70-year-old, who will also be the oldest first-term president to take office, defied months of polls predicting a Clinton victory, which stretched all the way to the actual vote count.
With a strong showing in elections to the Senate and the House of Representatives, the Republican Party was poised to have unified control of the White House and both chambers of Congress for the first time since Mr George W. Bush's first term in office in 2001.
Mr Trump now faces the difficult challenge of bringing together a nation torn apart by the campaign. He had railed against some minority Americans during his campaign.
He is likely to be only the fifth president to win without securing the popular vote. Both he and Mrs Clinton have so far secured less than 48 per cent of ballots cast and counted, with the rest split among other candidates.
His perceived volatility also sent global markets into a tailspin, with oil prices and the US dollar diving, while gold prices rose as investors fled to safety.
Mr Trump sought to address some of the biggest concerns in his victory speech in New York. He graciously praised Mrs Clinton, promised to unify the country and abandoned all the name-calling that had been a trademark of his campaign.
"Now it is time for America to bind the wounds of division," he said. "I pledge to every citizen of our land that I will be president for all Americans, and this is so important to me."
He also had reassuring words for other nations, saying: "While we will always put America's interests first, we will deal fairly with everyone, with everyone - all people and all other nations. We will seek common ground, not hostility; partnership, not conflict."
This came on the heels of his anti-trade message that resonated with white working-class voters in the rust belt, hit hard by globalisation. Their support helped him win Democrat strongholds like Wisconsin and Pennsylvania.
By press time, he had picked up 279 electoral votes - more than the 270 needed - and looked poised to get even more if he held on to his slim leads in Arizona and Michigan.
Last night's events upend years of conventional wisdom about what a triumphant campaign should look like.
The tycoon did not build up a grassroots network; raised only half the US$500 million (S$695 million) his opponent had and fell out with his own party's establishment members as his policies diverge from Republican orthodoxy.
Democrats, meanwhile, are still coming to terms with how a woman they considered such a qualified candidate lost to a newbie.
Mrs Clinton's much vaunted advantage with women and minorities never really materialised, with exit polls showing Mr Trump gaining a large chunk of the Hispanic vote in a whole swathe of states.
But with his own legacy now in question, President Barack Obama sought to soothe some of the angst that the bitter election had wrought.
In a taped message before the results, he said: "No matter what happens, the sun will rise in the morning and America will still be the greatest nation on earth."