The United States election was plunged into chaos early Wednesday as US President Donald Trump prematurely declared victory and sought Supreme Court intervention to stop vote-counting – even as his Democratic rival Joe Biden voiced confidence in his own chances.
In a divisive election cast under the shadow of the coronavirus pandemic that has claimed more than 230,000 lives in the United States, Trump appeared to have avoided a Democratic wave predicted by some polls but he still needs key states to secure another four-year term.
Shattering norms in the world's most powerful democracy, Trump alleged "major fraud" as he held an upbeat rally inside the White House's ceremonial East Room.
"We did win this election," Trump told cheering supporters, few of them wearing masks to protect from Covid-19. "This is a fraud on the American public."
The Republican tycoon said he would go to the Supreme Court because "we want all voting to stop."
Voting had already ended by the time Trump took the podium after 2am (0700 GMT) but Trump appeared to be calling for the court to stop counting.
Trump has railed for months against mail-in ballots, charging without evidence that they could be fraudulent, as some 100 million US citizens voted ahead of Election Day amid the health crisis.
The Biden campaign soon hit back, calling the president's bid to stop vote counting "outrageous" and "unprecedented," and saying its legal teams were ready to fight him in the courts if need be.
"The counting will not stop. It will continue until every duly cast vote is counted," it vowed.
Biden had earlier warned that vote counting would take a while as he greeted his own backers, who honked from cars at a socially distanced rally in his home state of Delaware.
"We believe we're on track to win this election," the 77-year-old former vice-president said. "Keep the faith, guys, we're going to win this."
Biden's remarks clearly unnerved Trump who immediately tweeted his claims of victory and fraud, leading Twitter to flag his comments as part of its effort against election disinformation.
Governor Tom Wolf of Pennsylvania, which is proving to be the vital prize, said that one million mailed-in ballots remained to be counted and promised that all counties would work "tirelessly" to complete them.
"Let's be clear," the Democrat said of Trump's comments. "This is a partisan attack on Pennsylvania's election, our votes and democracy."
Trump for the past four years has often been quick to say he is treated unfairly but even a few of his allies voiced unease at his dramatic intervention.
"Stop. Full stop. The votes will be counted and you will either win or lose. And America will accept that. Patience is a virtue," tweeted Adam Kinzinger, a Republican congressman who won reelection.
Foreign countries also sounded the alarm, with German Defence Minister Annegret Kramp-Karrenbauer warning that Trump could create a "constitutional crisis."
At least one state flips
Television networks predicted that Biden would be the first Democrat in 24 years to win Arizona, seizing on the southwestern state's changing demographics and the popularity of astronaut Mark Kelly who was projected to win a Senate seat.
But no other states immediately flipped and Trump won an early prize in Florida, where his hard line against Latin American leftists helped him make inroads among Cuban-US citizens.
Democratic hopes fizzled of turning around Texas, a Republican bastion indispensable for Trump, even though Biden came tantalisingly close in early results.
Biden, as expected, comfortably won the biggest prize of all, California, as well as New York and easily kept Minnesota and New Hampshire, two states where Hillary Clinton in 2016 had only eked out victories over Trump.
Attention was again turning to three states that elected Trump four years ago – Michigan, Pennsylvania and Wisconsin – with early ballots still waiting to be counted from the Democratic stronghold cities of Detroit, Philadelphia and Milwaukee.
Biden said he was feeling "real good" about Michigan and Wisconsin and voiced confidence about Pennsylvania, where he was born.
The former vice president said he was also competitive in Georgia – a state that until recently had not appeared to be in play – as election workers in its largest city Atlanta halted counting for the night after a pipe burst.
But Trump pointed to the total votes already counted as he insisted that he was winning the states, saying he was leading in Pennsylvania "by a tremendous amount of votes."
Fears of trouble
Pundits had been warning for weeks that this year's election results would take time – and voicing fear Trump would cause chaos or even violence by questioning the process.
While there were no immediate reports of unrest, stores boarded up throughout the capital Washington and, in an unusual move, foreign powers called for a violence-free election in the United States.
Outside the White House, a boisterous, peaceful protest in a plaza renamed for the Black Lives Matter movement turned heated as the night wore on, with scuffling after a person appeared to throw a gas cannister.
And in Portland, the centre of confrontations this summer between leftist protesters and police, some 400 people marched toward the downtown under a watchful eye of state police.