Voters in Michigan are heading to the polls on Tuesday, and they have a lot on their plates: Figuring out who will replace their unpopular governor, challenge their longstanding senator, and take over from a congressman who retired over sexual harassment allegations.

In the 7 August primary election, voters will select one candidate from each party to compete in the midterm elections this fall. Up for grabs are the governor’s mansion, one US Senate seat, and 14 different US House seats.

The state is primed for a possible Democratic upheaval, according to pollsters, with two traditionally Republican districts now seen as a toss-up between the two parties. The state was a surprise victory for Donald Trump in 2016, but now – with the president’s approval rating sitting at just 44 per cent across the state – things could look quite different.

Here are the midterm races you need to know about.

People in Macomb County, Michigan are still behind Trump after 100 days

Governor

A wide field of candidates is fighting to replace Republican Governor Rick Snyder, who was ranked the 10th least popular governor in the country by Morning Consult this February. Mr Snyder’s approval rating has slipped to just 35 per cent in the state, largely due to his handling of the water crisis in Flint.

The Democratic primary field is getting sizeable amounts of media attention, thanks in part to charismatic candidate Abdul el-Sayed, a young progressive who just scored the endorsements of Senator Bernie Sanders and congressional candidate Alexandria Ocasio-Cortez. But Mr el-Sayed is actually the least likely of the Democrats to come out on top, with state Senate Democratic leader Gretchen Whitmer and entrepreneur Shri Thanedar leading him in the latest polls.

Attorney General Bill Schuette is leading the pack on the Republican side, boosted by an early endorsement from Mr Trump (though president managed to misspell his name). Lieutenant Governor Brian Calley comes in second, according to a poll commissioned by the Detroit Free Press, with Senator Patrick Colbeck coming in a distant third.

A NBC/Marist matchup of the most popular candidate from each party predicted Ms Whitmer, the leading Democrat, would beat Mr Schette, the leading Republican, in the November general.

Abdul El-Sayed speaks with the news media after campaigning with New York Democrat candidate for Congress Alexandria Ocasio-Cortez US Senate (Bill Pugliano/Getty Images)

US Senate

Longtime Democratic Senator Debbie Stabenow faces no challengers from within her own party on Tuesday, and – according to the Cook Political Report – probably has little to fear from her Republican challenger in November. Nevertheless, business executives John James and Sandy Pensler are duking it out to run against her in the general election.

Mr Pensler – a Yale economist and venture capitalist – maintains a fundraising advantage, thanks to the $5m of his own money he donated to his campaign. Still, recent polls have him in a dead heat with Mr James, who recently secured an endorsement from Mr Trump.

“Rarely have I seen a candidate with such great potential. West Point graduate, successful businessman and a African American leader,” the president tweeted last month.

Senator Debbie Stabenow speaks with reporters following the weekly policy luncheons in Washington (Aaron P. Bernstein/Getty Images)

US House

All 14 US House seats from Michigan are fair game this year, but a few are attracting considerable outside attention. Two districts that usually lean Republican – the 11th and 8th – are of particular interest, because pollsters now rate them a toss-up.

The 11th district is especially interesting for its celebrity angle: Suneel Gupta, the brother of CNN personality Sanjay Gupta, is running in the Democratic primary. Others in the crowded, six-candidate field include Fayrouz Saad, who is running to be the first Muslim woman in US Congress, and Haley Stevens, who scored an endorsement from Hillary Clinton on Sunday.

In the 8th District, former CIA agent Elissa Slotkin looks likely to best Chris Smith, a professor at Michigan State University, in the Democratic primary. That would leave her to face off against current Republican Representative Bishop – who is seen as vulnerable despite his traditionally red district – in the November generals.

Also of interest is Michigan’s 13th, where longtime Democratic Representative John Conyers stepped down last year amid allegations of sexual misconduct. Mr Conyers has denied the allegations. His great nephew, state Senator Ian Conyers, had entered the race to replace him, competing against the Detroit city council president, a former state representative, and the mayor of a local town.