The majority of tech companies and tech employment in the US exists outside of San Francisco, New York, Los Angeles, Boston and Seattle.
There are 6.9 million technology jobs in the US currently. There are about 1.2 million technology jobs in all of California. Just Texas + Florida = 900,000. New York has close to 400,000.
So CA + NY = 1.6 million out of 6.9 million US technology jobs. Not all of those are located in SF, LA, NYC. Also of importance: a very large percentage of that tech workforce in California, consists of a small number of huge tech companies.
The slim minority of tech companies are located in locations with such extreme living expenses. They do represent the extreme outlier outcomes when it comes to producing iconic mega corporations (high value market capitalizations).
It turns out there is an extremely large economy outside of Silicon Valley. See:
Cyberstates 2017 Study
"The definitive state-by-state analysis of the U.S. tech industry"
http://www.cyberstates.org/pdf/CompTIA%20Cyberstates%202017....