Best public elementary school in California is in Cupertino. It is called William Faria. They have several years of scoring perfect 1000 on the API (Academic Performance Index). It is a school for the gifted.

Cupertino is the best school district for elementary schools in the entire state, with many fast track/gifted programs in elementary and middle schools.

High Schools in the Fremont School District (which Cupertino schools feed into) also have different tracks for advanced students and will provide accommodations where needed. The very respected and highly academically ranked De Anza Community College works with Fremont District High Schools students for dual enrollment when needed.

Best high schools are Monta Vista and Lynbrook, however Los Gatos school district's Saratoga High is a rival school that is just as competitive.

Silicon Valley on a whole has quite a variety of school districts, but these school districts (Cupertino, Fremont, Los Gatos) very much respect the students' needs, if they prove to need more of a challenge.

Here is a link that will show you last year's API scores. 1000 is perfect.

Santa Clara County List of API Scores