Refraction traveltimes from a 46-km long seismic survey across the San Andreas Fault were inverted to obtain two-dimensional velocity structure of the upper crust near the SAFOD drilling project. The model contains strong vertical and lateral velocity variations from <2 km/s to ???6 km/s. The Salinian terrane west of the San Andreas Fault has much higher velocity than the Franciscan terrane east of the fault. Salinian basement deepens from 0.8 km subsurface at SAFOD to ???2.5 km subsurface 20 km to the southwest. A strong reflection and subtle velocity contrast suggest a steeply dipping fault separating the Franciscan terrane from the Great Valley Sequence. A low-velocity wedge of Cenozoic sedimentary rocks lies immediately southwest of the San Andreas Fault. This body is bounded by a steep fault just northeast of SAFOD and approaches the depth of the shallowest earthquakes. Multiple active and inactive fault strands complicate structure near SAFOD. Copyright 2006 by the American Geophysical Union.