Democrat Jill Karofsky has ousted Justice Daniel Kelly from his seat at Wisconsin’s top court in a shock win.
The election went ahead despite Democrat calls for it to be postponed, or held by postal voting, owing to coronavirus fears.
Justice Kelly is just the second incumbent state Supreme Court justice to be voted out since 1967. He had the support of President Donald Trump.
Wisconsin is expected to be crucial in the presidential election in November.
Former Vice-President Joe Biden will likely become the Democratic Party challenger to President Trump after his main rival Bernie Sanders dropped out and publicly endorsed him.
The US is now the country worst hit by the coronavirus pandemic with 582,594 confirmed cases and 23,649 deaths.
Wisconsin has recorded more than 3,400 coronavirus cases and 154 deaths.
The Wisconsin Supreme Court vote – and the Democratic Party primary election – went ahead last week, after the same court blocked the governor’s effort to postpone it to June.
Voters braved long queues at a limited number of polling stations where some staff wore hazmat suits.
Judges had ordered a delay in the publication of results to make sure absentee votes had arrived and been included in the count.
“Despite the result, the fact that this in-person election took place was a searing loss for Wisconsin,” said Ben Wikler, the chairman of the Wisconsin Democratic Party. “Wisconsin voters will not forget this travesty.”
Wisconsin was the first state in a month to hold a primary with in-person voting since stay-at-home orders swept the US due to the pandemic. The Badger state imposed its own lockdown on 25 March.
All other states have postponed their primary season elections or moved entirely to postal votes while the country remains in the throes of its health emergency.
Dane County Judge Jill Karofsky’s win for the 10-year term reduces the conservative majority in the top court to 4-3.
The court is expected to decide a case that seeks to purge more than 200,000 people from Wisconsin’s voter rolls.
The issue is sensitive in a state where presidential elections have been decided by fewer than 30,000 votes. Mr Trump won Wisconsin in 2016.