By HOLLY RAMER Associated Press

CONCORD, N.H. (AP) — Bill Gardner, the nation’s longest-serving secretary of state who built a reputation for fiercely defending New Hampshire’s position at the front of the presidential primary calendar, said Monday he will be leaving office this week.

Gardner, 73, was first elected by the Legislature in 1976. He was reelected to his 23rd two-year term in 2020 with no challengers. Historically, he faced little competition until 2018, when he defeated former gubernatorial candidate Colin Van Ostern by just four votes.

READ MORE: Man Killed In Roxbury Double Stabbing Defended Other Victim; GPS Monitor Used To Find Suspect

He said he will transfer power to Deputy Secretary of State David Scanlan.

Gardner has staunchly guarded New Hampshire’s first-in-the-nation presidential primary. New Hampshire law requires the state’s presidential primary to be held at least seven days ahead of any similar contest, and gives the secretary of state exclusive authority to set the date.

In 2020, New Hampshire’s Feb. 11 presidential primary race was under extra scrutiny after the leadoff Iowa caucuses descended into chaos, with technical problems and results that remained muddied for days.

READ MORE: PHOTOS: Truck Gets Stuck In NH Lake After Falling Through Ice

Then came the coronavirus pandemic, which created challenges for municipal elections and traditional Town Meetings in March, followed by the September state primary and November general election. The state temporarily expanded eligibility for absentee voting for those concerned about the pandemic, and extensive safety measures were in place at the polls. All of that influenced his decision to run again in 2020, Gardner said.

Gardner, a Democrat, has not traditionally accepted campaign donations.

“That to me is extremely important in protecting the nonpartisian tradition of this office,” he said at the time.

In recent years, Gardner came under fire from Democrats for his participation in former President Donald Trump’s commission on voter fraud and for backing GOP legislation to tighten voter registration rules. That created an opening for Van Ostern, who campaigned for months on a platform of modernizing the office, holding it accountable and resisting what he viewed as voter suppression measures.

MORE NEWS: 19-Year-Old Stabbed While Fighting Off Melrose Home Invasion Suspect 'Thought She Was Dreaming'

(© Copyright 2022 The Associated Press. All Rights Reserved. This material may not be published, broadcast, rewritten or redistributed.)