Harper, a trustee for 12 years with the Huntington Beach Union High School District, received 15,886 votes, while Shaw, a former planning and public works commissioner, finished with 14,585.
In the days after the election, as the Registrar counted provisional ballots, Shaw held a narrow lead over Planning Commissioner Barbara Delgleize, who trailed him by less than 500 votes. In the end, Delgleize came in fifth with 14,171.
"The provisional ballots were going to be in our favor, I thought," Shaw said. "Everybody worked hard. All the campaigns worked hard. The close race is a testament to that. So I'm glad my hard work paid off. When it's this close, all the little things you did amounted to changing the outcome."
For Huntington Beach city attorney, incumbent Jennifer McGrath held her lead over challenger T. Gabe Houston with 72.5% of the vote.
Voters passed Measures N, which makes changes to the city's charter, and Measure P, which amends the utility user tax. They rejected Measure O, which would have reformed infrastructure funding, and Measure Q, which asked voters' opinions on a pair of cell towers in public parks.
Collins was the only incumbent winning reelection in Fountain Valley. He led all candidates with 8,716 votes, while challengers McCurdy and Vo followed with 6,945 and 6,456, respectively. Incumbents Cheryl Brothers and Guy Carrozzo finished fourth and fifth.