Earlier quoted context omitted.
This is a ridiculous trope which keeps getting trotted out. You can easily live in SV for under $100k/year. You can earn >$200k as an engineer in SV (and in few other places). SV is almost certainly going to leave you with more money in your pocket than working at the average tech job.
The ">$200K/yr engineer" is also a ridiculous trope. I'm sure there are a handful of outlier engineers at top companies making that, but the median base Software Engineer salary in the Bay Area is anywhere from $100k to $105k depending on your source (+ maybe a few K in equity depending on the company).
I am a fairly mediocre engineer. I have less than a decade of experience and have never worked at a "top" company. Yet I earned over $200k last year.