Buying in the Bay Area is not that bad. It's a matter of trade-off, as with many things in life. You won't get huge lot or huge house for the cheap for sure, but there are other factors making up for it. For one thing the weather is fantastic. The food are amazing. It's closer to the tech center if that's your priority.
I just bought a house outside the bay area last year, and tacked on a partial remodel with new wiring, heat pump, water heater, and bathroom.
My required payment -- including escrow for taxes, insurance, and (for now) PMI -- is comparable to the rent for a mediocre single-bedroom apartment in a sketchy area of the south bay. I'll be adding enough each month to have it paid off in 10-15 years.
For that, between the main level and the basement, I have around 2300 square feet that I can use as I wish, and I can modify it freely to suit my needs and wants.
But I would never buy a house in the bay area, at least not unless I had $20m+ in the bank.