Updated

Republican Sen. Cindy Hyde-Smith held onto the seat she was appointed to earlier this year after she defeated Democrat Mike Espy in the Nov. 27 runoff election – the final Senate race to be decided in the 2018 midterm elections.

She will finish the final two years of a term started by GOP Sen. Thad Cochran, who resigned in April due to health issues. She is also the first woman ever elected to the Senate by Mississippi.

Her victory gives Republicans a net gain of two Senate seats in the midterm elections and a 53-47 advantage in the upper chamber, a margin that could prove critical in contentious confirmation battles to come.

Read on for a look at what to know about the candidates and the runoff election.

Who was running?

Democrat Mike Espy and Republican Cindy Hyde-Smith advanced to the runoff election after the Nov. 6 contest.

Democrat Mike Espy and Republican Cindy Hyde-Smith advanced to the runoff election after the Nov. 6 contest. (AP Photo)

Hyde-Smith and Espy advanced to the runoff after the Nov. 6 election.

Hyde-Smith was appointed to the seat earlier this year after GOP Sen. Thad Cochran retired due to health issues. The 59-year-old is the state’s first female senator.

Prior to her appointment, Hyde-Smith worked as Mississippi’s agriculture commissioner. She also served as a state senator until 2012, initially as a Democrat before switching parties in 2010.

Espy, 64, was the Agriculture secretary during the Clinton administration. Prior to that, Espy represented Mississippi in Congress. If he had been elected, Espy would have been Mississippi’s first black senator since the Reconstruction era.

Espy considers himself a “moderate” on many issues, including abortion, according to The Clarion-Ledger. While he told the newspaper he opposes abortion, he believes Roe v. Wade is settled “law of the land.”

President Trump endorsed Hyde-Smith and campaigned with her ahead of the runoff election.

Why was there a runoff?

In Mississippi, candidates compete in a jungle primary – meaning, all candidates ran in the November election.

On Nov. 6, four candidates sought the Senate seat: Hyde-Smith, Espy, Republican Chris McDaniel and Democrat Tobey Bernard Bartee. Since no candidate gained more than 50 percent of the vote, Espy and Hyde-Smith headed for the Nov. 27 runoff.

Anything else to know?

Both Espy and Hyde-Smith dealt with controversies throughout their campaigns.

Espy has faced some ethical questions for past work he’s done, including raking in $750,000 for lobbying work done on behalf of an African despot currently on trial for crimes against humanity at the International Criminal Court. Espy appeared to have misled people about how much he made for the work and when exactly he terminated his contract with the Ivory Coast.

Additionally, Espy was criticized for working for a company that paid $2.5 million to settle a lawsuit concerning bribing of officials in a bid to score lucrative contracts with Mississippi’s state prison.

Espy left Clinton’s Cabinet after he was accused of improperly taking gifts and indicted on 30 felony charges. However, he was acquitted of any wrongdoing by a jury.

Hyde-Smith, meanwhile, made a series of gaffes on the campaign trail.

She apologized after a video was released of her praising a local cattle rancher by saying, “If he invited me to a public hanging, I’d be on the front row.” The remark struck a nerve with many in Mississippi, given its history of lynchings.

Hyde-Smith again ignited controversy after she was an old photo of her wearing a replica hat of a Confederate soldier circulated.

She was also under intense scrutiny for having graduated from a white private school that was founded after court-ordered desegregation of public schools. According to the Jackson Free Press, schools such as Lawrence County Academy were created so “white parents could avoid having to send their children to schools with black students.”

Multiple companies and organizations – including the MLB, Walmart and Union Pacific – requested campaign donations be returned following the public hanging comment.

Fox News’ Lukas Mikelionis, Gregg Re and The Associated Press contributed to this report.