SAN JOSE, Calif. (KRON) – Tech entrepreneur-turned-politician Matt Mahan is ahead of Santa Clara County Supervisor Cindy Chavez in the race to succeed Sam Liccardo as mayor of the capital of Silicon Valley, according to preliminary election returns.

Mahan has won 51.7% of the vote, compared to 48.2% won by Chavez, according to the Santa Clara County Registrar of Voters.

Chavez, a former vice mayor of San Jose, had been endorsed by the county Democratic Party and bested Mahan 39%-32% in June’s jungle primary. But Mahan, who began representing southern San Jose last year, had the endorsement of the San Jose Mercury News and Liccardo.