The cost of building probably does have an effect on the margin, but it is so much less of a factor than restrictions on what can be built.
http://www.smdailyjournal.com/news/local/millbrae-bart-stati...
From the National Association of Home Builders, it looks like "average" is approximately $9,400 per unit in "fees". Not sure if that's apple to apples with the Bay Area, but in either way that fee just seems kind of crazy. Rows A-C, summing fees, on the Construction Costs table here: https://www.nahbclassic.org/generic.aspx?genericContentID=24...
The other problem is that housing developers in California have a tendency to build huge, sprawling suburban communities. This just increases sprawl.
Imagine a 1 sq. mile tract of land. Assuming a housing developer builds a ton of two story, single family homes here, each on a 1/4 acre of land, we can calculate that they can build 2560 homes +/- 500 based on topography and landscaping etc. There are no reliable numbers as to the average of units in an apartment building. Therefore, we will have to make some assumptions. Let's go ahead and say that that the developer decides to build apartments instead of tract-homes. Each apartment building will be 2 acres in area. Even if the apartments are huge: 1500 sq ft +, we can calculate that a 2 acre apartment building can have about 20 units per floor. Lets say that these apartment buildings are a modest 2 stories tall. 20 * 2 = 40. That means, covering the same 1 sq. mile of land with modest apartment buildings could create 12800 residences. That's a 500% increase in residences.
In urban centers, zoning laws allow for much taller structures. Structures can be hybridized to allow for both commercial and residential tenants.
Building large, hybrid-use, multi-tenant structures will alleviate some of the pressure on the housing market and lead to shorter commutes for most people. This is because you can fit more people into a smaller land area. It's common sense I'm sure. So, why aren't developers building these structures? The short answer is that they can't. City zoning laws, angry property owners, and the lack of open land in desirable areas all get in the way.
Then I looked at the zoning map for the municipality, and read the zoning codes.
From outward appearances, it's to keep the poor people away from the rich people. And not just at night when everyone goes home, either. All the time, everywhere. Jobs, schools, commutes, shopping, entertainment. It's the new age of redlining, with a global substitution of bank account sizes for skin colors.
I couldn't tell what degree of intent was there, but on the ground, the zoning board has reinvented the ghetto. The poor folks get to live next to the railroad tracks. Rich folks get to live next to the zone marked as protected wetland/watershed, so that it can never be developed.