As a rule, most places you are not allowed to go and "squat" at. How long do you plan on camping in one spot? Do you want to hike in or camp by your car? There are state parks and private campgrounds where you can drive up and camp on/near the beach. At those you can only stay maybe a week. There are other lands where you have to backpack in and can stay maybe 3 nights. Most places however you are not allowed to sleep at period.
To the other poster, fires are allowed on Ocean Beach but there are restrictions. I think that they might only be allowed north of the Safeway or something. On a busy summer night however there will be large groups of people having bonfires all along the beach.
Do not expect winter in Northern California to be warm. You will be by the ocean, prepare for the weather. Some camping areas around the bay area where you can camp near or on the beach are: Kirby Cove (under the golden gate bridge but only in the summer), Steep Ravine (rustic cabins and camping near stinson beach), and Point Reyes (backpacking campgrounds). I also know there are lots of campgrounds on the north coast.