A special election was held for mayor of the City and County of San Francisco on June 5, 2018, to fill the remainder of the term of Ed Lee, who had died in office on December 12, 2017. Upon Lee's death, London Breed, president of the San Francisco Board of Supervisors, became acting mayor of San Francisco, but a vote of six supervisors replaced Breed with Supervisor Mark Farrell. The mayoral election was held concurrently with the statewide direct primary election. In San Francisco, the election for the eighth district member of the board of supervisors was also on the ballot.