After the drama of election night and fierce battles about counting votes, Florida Secretary of State Ken Detzner on Saturday ordered recounts in high-stakes races for U.S. Senate, Governor and Agriculture commissioner.

The orders, along with recounts slated in three legislative districts, were no surprise: State law requires “machine” recounts when the margins between candidates are 0.5 percent or less. As local officials continued to count ballots after Tuesday’s election, it became clear that all six of the races would fall under that requirement.

The machine recounts will play out over five days, with county canvassing boards required to report results by 3 p.m. Thursday. At that point, races with margins of .25 percent or less will go to manual, or “hand,” recounts.

Counties were required by noon Saturday to report unofficial results to the state. The races set for recounts are:

— The U.S. Senate race between Democratic incumbent Bill Nelson and Republican Gov. Rick Scott. In the unofficial results, Scott had 4,098,107 votes, or 50.07 percent, while Nelson had 4,085,545 votes, or 49.92 percent.

— The Governor’s race between Republican Ron DeSantis and Democrat Andrew Gillum. In the unofficial results, DeSantis had 4,075,879 votes, or 49.59 percent, while Gillum had 4,042,195 votes, or 49.18 percent.

— The race for Agriculture Commissioner between Democrat Nikki Fried and Republican Matt Caldwell. In the unofficial results, Fried had 4,030,337 votes, or 50.03 percent, while Caldwell had 4,025,011 votes, or 49.97 percent.

— The race in Hillsborough County’s state Senate District 18 between Sen. Dana Young, a Tampa Republican, and House Minority Leader Janet Cruz, a Tampa Democrat. In the unofficial results, Cruz had 104,001 votes, or 50.09 percent, while Young had 103,625 votes, or 49.91 percent.

— The race in Volusia County’s House District 26 between Rep. Patrick Henry, a Daytona Beach Democrat, and Republican Elizabeth Fetterhoff. In the unofficial results, Fetterhoff had 30,591 votes, or 50.05 percent, while Henry had 30,532 votes, or 49.95 percent.

— The race for an open seat in Palm Beach County’s House District 89 between Republican Mike Caruso and Democrat Jim Bonfiglio. In the unofficial results, Caruso had 39,228 votes, or 50.02 percent, while Bonfiglio had 39,191 votes, or 49.98 percent.

In a machine recount, all ballots are fed through voting machines. Ballots with “undervotes” or “overvotes” — in which voters may have skipped races or made extra marks in races, causing their ballots to be rejected by the machines — are set aside, or “outstacked.”

In races that go to manual recounts after the Thursday deadline, county canvassing boards will examine the “outstacked” ballots.

The results from the manual recounts must be provided to the state no later than noon on Nov. 18. Two days later, the state Elections Canvassing Commission, comprised of Scott and two members of the Florida Cabinet, will meet in Tallahassee to certify the official election results.