Donald Trump and Joe Biden are each claiming victory in Tuesday’s White House race, even as the final outcome hangs on a razor’s edge and both sides ramp up for legal action.
The Trump campaign is challenging vote counts in the critical states of Wisconsin, Pennsylvania and Michigan.
The BBC projects Mr Biden won Michigan. US media forecast he has won Wisconsin. No result has emerged in Pennsylvania.
Winning all three of these Rust Belt states would make Mr Biden victorious.
On Wednesday afternoon, Mr Biden said in Wilmington, Delaware: “When the count is finished we believe we will be the winners.”
He added: “I will govern as an American president. The presidency itself is not a partisan institution.”
The Democratic challenger said his campaign was feeling “very good” about Pennsylvania.
Not so fast, said the campaign of Republican President Trump.
“We are declaring victory in Pennsylvania,” said campaign manager Bill Stepien on a press call. “This is not based on gut or feel. This is based on math.”
“If we count all legal ballots, we win,” he added.
Senior Trump campaign aide Jason Miller said: “By the end of this week it will be clear to the entire nation that President Trump and Vice-President Pence will be elected for another four years.”
Mr Biden has the edge in the race to accumulate the 270 Electoral College votes needed to win the White House. The Democrat has 243 votes, while the Republican has 214.
In the US election, voters decide state-level contests rather than a single, national one. Each US state gets a certain number of electoral college votes partly based on its population and there are a total of 538 up for grabs.
If Mr Trump does lose Wisconsin, he must win Georgia, North Carolina, Pennsylvania and either Arizona or Nevada to prevail.
The president has a one-point lead in both North Carolina and Georgia and the two remain neck-and-neck with most votes counted in Nevada. The Trump campaign is hopeful it can still take Arizona.
Mr Biden has a three-point advantage in the once reliably conservative sunbelt state with nearly 90% of votes counted, and CBS has categorised it as a “likely” win for the Democrat.
But the state’s Republican Governor Doug Ducey said in a statement on Wednesday: “The results have shifted greatly hour by hour, and from last night until today.
“With hundreds of thousands of votes still outstanding it’s important that we be patient before declaring any races up or down the ballot.” His remarks amounted to an implicit rebuke of Fox News, which called the state early for Mr Biden on election night.
The Trump campaign said the president would formally request a Wisconsin recount, citing “irregularities in several Wisconsin counties”.
Incomplete results indicate the margin between Mr Trump and Mr Biden in Wisconsin is less than one percentage point, which allows a candidate to seek a recount.
The campaign also filed a lawsuit in Michigan to stop counting of ballots there because it contended it was denied “meaningful access” to observe the opening of ballots and the counting.
In Detroit, Michigan, police were called on Wednesday afternoon to guard the doors to a vote-counting facility as some protesters outside demanded access to monitor the process. According to the Detroit Free-Press, there were already some 200 people observing the vote inside the building.
Officials were seen covering up the windows to the TCF Center, where postal ballots were being tallied.
The Trump campaign also filed two lawsuits in Pennsylvania to halt all vote counting “until there is meaningful transparency”.
The president has a five-point lead in the Keystone state, but hundreds of thousands of votes remain to be counted.
The Associated Press news agency reports that the Trump campaign is also suing Georgia to halt the vote count there.
Mr Trump won Wisconsin, Michigan and Pennsylvania in his 2016 election victory.
In the early hours of Wednesday, he announced from the White House that he had won and said he would take the election to the Supreme Court.
The Trump campaign is asking Republican donors to help fund legal challenges.
Republican National Committee Chairwoman Ronna McDaniel said: “The fight’s not over. We’re in it.”
Mr Biden’s running mate, Kamala Harris, tweeted asking supporters to contribute $5 to help pay for a fight that could “stretch on for weeks”.
Biden campaign senior legal adviser Bob Bauer said there were no grounds for Mr Trump to invalidate lawfully cast ballots.
Mr Biden’s hopes of a decisive early victory on election night were thwarted as Mr Trump defied pollsters predictions by outperforming in key battlegrounds.
Mr Trump held several important states, including Texas, Ohio and Iowa, fending off a strong Biden play.
The president also comfortably won his adopted home state of Florida, the most hotly fought battleground of the night, despite two visits there by Mr Biden’s ally and former boss, ex-President Barack Obama.
But Mr Biden fended off his rival’s attempts to pick up New Hampshire and Minnesota.
Democrats’ hopes of winning control of the Senate appeared to be dwindling as the dust settled from election day.
They were projected to win two seats in Colorado and Arizona, but lost a seat in Alabama.
Senate races in North Carolina and Michigan remained undecided, and another race in Georgia was heading for a run-off vote in January.
But Senate Majority Leader Mitch McConnell said he felt “pretty good” about the remaining contests. Republicans currently control the chamber by 53-47.
Mr McConnell and Trump ally Lindsey Graham were both re-elected in their seats of Kentucky and South Carolina respectively.
Mr Graham said of the $100m challenge he brushed off from Democrat Jamie Harrison: “This is the worst return on investment in the history of American politics.”
Republicans also held on to other Senate seats in Maine, Montana, Texas and Iowa.
And there was an unexpected setback for Democrats in House of Representatives races. The party had hoped to gain 15 seats in the lower chamber of Congress, which they currently control.
But instead they face a lower majority as five of their incumbents lost and they failed to beat a single Republican.
One of the incoming Republicans lawmakers, in Georgia, has been described as a supporter of the bizarre, pro-Trump QAnon conspiracy theory.