Updated

Wisconsin completed a partial recount Sunday, which added to President-elect Joe Biden's lead in the 2020 presidential election by an additional 87 votes ahead of Tuesday, when the state is set to certify results.

President Trump vowed to challenge the outcome in court even before the recount concluded. He spent $3 million to force a recount.

BIDEN GETS BOOST FROM WISCONSIN RECOUNT THAT COST TRUMP $3M

"The Wisconsin recount is not about finding mistakes in the count, it is about finding people who have voted illegally, and that case will be brought after the recount is over, on Monday or Tuesday," Trump wrote on Twitter on Saturday. "We have found many illegal votes. Stay tuned!"

Dane County was the second and last county to finish its recount, reporting a 45-vote gain for Trump. Milwaukee County, the state's other big and overwhelmingly liberal county targeted in a recount that Trump paid for, reported its results Friday, a 132-vote gain for Biden.

Taken together, the two counties barely budged Biden's winning margin of about 20,600 votes, giving the winner a net gain of 87 votes.

Workers count Milwaukee County ballots on Election Day at Central Count on Tuesday, Nov. 3, 2020, in Milwaukee. (AP Photo/Morry Gash)

Democratic lawyer Marc Elias celebrated the news on Sunday. 

"Trump becomes the first presidential candidate in history to lose recounts in two different states. Trump and his allies remain 1-39 in post-election litigation," Elias wrote on Twitter.

Certification is done by the Democratic chair of the Wisconsin Election Commission, which is bipartisan.

The Wisconsin Voters Alliance, a conservative group, has already filed a lawsuit against state election officials seeking to block certification of the results. It makes many of the claims Trump is expected to make. Gov. Tony Evers’ attorneys have asked the state Supreme Court to dismiss the suit. Evers, a Democrat, said the complaint is a “mishmash of legal distortions” that uses factual misrepresentations in an attempt to take voting rights away from millions of Wisconsin residents.

DONOR SUES PRO-TRUMP GROUP FOR $2.5M OVER 'EMPTY PROMISES' ON VOTER FRAUD

Another suit filed over the weekend by Wisconsin resident Dean Mueller argues that ballots placed in drop boxes are illegal and must not be counted.

Trump’s attorneys have complained about absentee ballots where voters identified themselves as “indefinitely confined,” allowing them to cast an absentee ballot without showing a photo ID; ballots that have a certification envelope with two different ink colors, indicating a poll worker may have helped complete it; and absentee ballots that don’t have a separate written record for its request, such as in-person absentee ballots.

CLICK HERE FOR THE FOX NEWS APP

Election officials in the two counties counted those ballots during the recount, but marked them as exhibits at the request of the Trump campaign.

The Associated Press and Fox News' Vandana Rambaran contributed to this report.