We present an analysis of shear velocity anisotropy using data in and near the San Andreas Fault Observatory at Depth (SAFOD) to investigate the physical mechanisms controlling velocity anisotropy and the effects of frequency and scale. We analyze data from borehole dipole sonic logs and present the results from a shear-wave-splitting analysis performed on waveforms from microearthquakes recorded on a downhole seismic array. We show how seismic anisotropy is linked either to structures such as sedimentary bedding planes or to the state of stress, depending on the physical properties of the formation. For an arbitrarily oriented wellbore, we model the apparent fast direction that is measured with dipole sonic logs if the shear waves are polarized by arbitrarily dipping transversely isotropic (TI) structural planes (bedding/fractures). Our results indicate that the contemporary state of stress is the dominant mechanism governing shear velocity anisotropy in both highly fractured granitic rocks and well-bedded arkosic sandstones. In contrast, within the finely laminated shales, anisotropy is a result of the structural alignment of clays along the sedimentary bedding planes. By analyzing shear velocity anisotropy at sonic wavelengths over scales of meters and at seismic frequencies over scales of several kilometers, we show that the polarization of the shear waves and the amount of anisotropy recorded are strongly dependent on the frequency and scale of investigation. The shear anisotropy data provide constraints on the orientation of the maximum horizontal compressive stress and suggest that, at a distance of only 200 m from the San Andreas fault (SAF), is at an angle of approximately 70° to the strike of the fault. This observation is consistent with the hypothesis that the SAF is a weak fault slipping at low levels of shear stress.