Apparently the last time there was a fatal shark attack in Northern California was in 2004, and it was an abalone diver.
Northern California is notorious for sharks and shark attacks, but haven't had any fatalities in a while.
Central California had at least a couple fatal attacks since then, two that I can recall were at the same beach, which does not get surfed very often because it is notorious for shark sightings. It is the closest piece of land to the great white shark birthing ground which is just west of the channel islands.
Southern California has had a fatal attack on a swimmer, another swimmer and a lobster diver were wounded not too long ago as well.
Surfers seem to be fairly safe from shark attacks compared to swimmers, bodyboarders and divers. If you look at the shear number of surfers in the water on any given day on any given stretch of beach, there are far more surfers than ocean swimmers (not waders) and divers and bodyboarders for that matter.. Even San Francisco's ocean beach attracts up to thousands of surfers on a given day if the conditions are good, and the Farallon Islands which is the local mating ground for great whites is offshore only about 30 miles from there.
But it can definitely happen.