Despite a pressing demand for new homes, condos and apartments, residential building permits in California fell 16 percent in the last year, dropping for the first time since the recession nearly a decade ago.

In the Bay Area, permits to build new homes and apartments tanked — falling nearly 50 percent in San Mateo County compared with the prior year, 30 percent in Alameda County, nearly 10 percent in Santa Clara County and 7 percent in Contra Costa County, according to a new analysis by the Public Policy Institute of California.

“At this point, it’s become a noticeable decline,” said Hans Johnson, a senior fellow at PPIC in San Francisco. “It’s the start of a worrisome trend.”

The drop in building permits, a leading indicator of how many new housing units will get built, comes as the state and region battle a gaping deficit of housing. Planners estimate the state needs about 3.5 million units to adequately house its population, and Gov. Gavin Newsom set a goal of adding that many homes and apartments by 2025.

But lawmakers this year shelved several major housing proposals that would have made it easier for developers to build. The rolling Bay Area economy and pent up demand drove housing prices on a record streak upward from 2012 to the beginning of 2019, shutting out many potential buyers. The region has added far more jobs than homes in recent years.

Steve Levy, director of the Center for Continuing Study of the California Economy, said permits had been steadily climbing since recovering in 2010 from a steep drop-off during the recession.

But despite strong demand and job growth, he said, developers are waiting longer to start projects after they’ve acquired the land and approval from local city councils. Rising prices for scarce labor and materials have driven up costs and made bankers and developers more cautious about financing and starting projects.

The growing scope of U.S. tariffs on Chinese goods also has driven up expenses for building materials, he said. “Costs have to come down to unlock the permit,” Levy said.

But even before the tariffs, Bay Area construction costs were on the rise. A survey released by Turner & Townsend earlier this year found the Bay Area is the most expensive market in the world to build at $417 per square foot — higher even than New York, London and Hong Kong. Commercial development costs in the Bay Area grew 5 percent last year, and the company expects another 6 percent leap this year.

The analysis by the PPIC captured U.S. Census data of building permits issued by California counties between the 12-month period of July 2018 through June 2019. Despite the many highly visible construction projects, some were granted permits more than a year ago. The downward trend also does not reflect the many major commercial projects sprouting in the Bay Area.

The state averaged about 200,000 units annually between 2003 and 2005. Last year, the number fell to 93,000, about half of which were multi-family projects.

In the Bay Area, only San Francisco County managed to buck the trend, seeing a two-thirds increase in building permits during the period.

The numbers have turned even bleaker in recent months, during the prime building season. Permits fell 38 percent in June from the previous year, according to PPIC.

Johnson also pointed to growing costs as a reason for the slowdown, as well as the lack of land available for development, and a shortage of construction workers. Some of the recent construction has been driven by rebuilding homes destroyed by fires in Sonoma and Napa counties, replacing units but not addressing the state’s backlog, he said.

Johnson added that local boards and city councils opposed to new projects have slowed new development. “We already have a deficit of houses,” he said. “Local decisions certainly play a role.”