Erika Velez considers herself lucky. A 31-year old single mother in San Antonio, she had been struggling to find a place to live since last June, when she fell behind on rent and spent months bouncing between sleeping on friends’ couches and in her car.

Then in November she received a call that brought tears to her eyes: A two-bedroom house at Mirasol Townhomes, a public housing development of townhouses and single-family homes, had opened up for just $675 a month. Her previous monthly rent of $950 strained her salary as a dispatcher for a home cleaning service. But now she could afford a home with money to spare for herself and her 8-year-old daughter, who plastered her new bedroom with pictures of favorite anime characters.

“There’s a lot of people in San Antonio who struggle with finding housing,” Ms. Velez said. “It’s just out of their price range.”

Her experience echoes the broad challenges created by an affordable housing shortage in the United States. Builders have been stymied since the pandemic by higher costs for materials and labor, stricter lending practices, rising interest rates and supply chain hiccups.

The uncertainty threatens to further slow the process of building affordable homes. So many developments have been sidetracked or delayed that some experts expect a “production cliff” to hit in a year or so, meaning fewer new homes coming onto the market.

“When I started my career 30 years ago, the topic of affordable housing was usually limited to really lower-income clientele, industries and jobs,” said Albert Milo, president of the affordable housing division of the Related Group, an urban developer. “Now, it’s diametrically different. Most areas of the country are talking about teachers, police officers, nurses, professionals struggling to find housing that is affordable for their income.”

In 2021, 160,000 affordable homes and apartments were produced nationwide, said Benson Roberts, president and chief executive of the National Association of Affordable Housing Lenders.

But industry setbacks have decreased the likelihood that the nation will fill its shortage of affordable homes. The gap widened by more than 500,000 homes during the pandemic, leaving a national shortage of 7.3 million homes for extremely low-income renters, according to the National Low Income Housing Coalition.

“Just as pandemic eviction moratoriums were expiring and resources were being depleted, the lowest-income renters entered a really brutal housing market,” said Diane Yentel, the president and chief executive of the housing coalition. “Rents are skyrocketing, costs across the board have increased with heightened inflation, and they have few to no resources to pay.”

Costs for materials and labor remain stubbornly high. Developers are responding by cutting back, including eliminating amenities, using cheaper materials, setting higher income cutoffs and reducing the number of affordable apartments on projects that mix affordable and market-rate homes.

For affordable housing, builders and financiers cobble together different sources of public and private funding. But piecing together the “capital stack” — the complete financing package, which can include loans, tax credits and subsidies — has become more challenging.

Lenders have become skittish about investing after several midsize banks failed this year. Interest rates are climbing fast, adding to costs. Every quarter-point increase in the cost of loan can add a million dollars to the cost of their developments, said Jonathan Gertman, senior vice president at the NRP Group, an affordable housing developer.

A key federal tool to finance these builders, the Low-Income Housing Tax Credit program, has lost some of its value as interest rates have climbed, and the volume of loans issued by the Department of Housing and Urban Development for apartment buildings has fallen by half this year. Even operating expenses for existing buildings have risen, which means companies that run them make less money, hampering their ability to invest in new projects.

“It’s the most difficult time I’ve seen in my 30 years in business, a pretty bleak picture,” said Rafael E. Cestero, chief executive of the Community Preservation Corporation, a nonprofit affordable housing financier in New York.

The overwhelming majority of affordable housing that is built comes from private developers that team up with public agencies and tap public subsidies.

Late last year, the NRP Group was trying to rescue a deal to build Los Arcos at Vida, an affordable project in San Antonio. Construction costs were originally $110,000 a unit in April 2021, but by December, interest rates had soared and the per-unit cost jumped to $151,000. NRP found itself $7.75 million short and in trouble, because much of its public funding was contingent on the deal’s closing that year.

“Our motto here is, time kills deals,” said Debra Guerrero, NRP’s senior vice president of strategic partnerships and government affairs. Luckily, NRP was able to close the gap through city bonds and federal funding and break ground.

Developers need to navigate the same city zoning regulations and permitting processes that regulate all construction projects. The industry needs reforms of zoning codes and more federal funding, said Jenny Schuetz, a Brookings Institution researcher and housing expert. The policies are simple, she added, but the politics of making them reality are challenging.

Local governments, including in Montana and Massachusetts, have increasingly altered zoning and permitting practices to speed up building. Others have invested pots of “soft money” — long-term loans with exceptionally low interest rates.

San Antonio, the most impoverished major city in the country, according to census data, has enacted policies to help low-income renters, including a $150 million bond issue to support affordable housing construction and a Strategic Housing Implementation Plan. Before the pandemic, the wait list for public housing in San Antonio was roughly 35,000 families, earning an average of $11,000 annually, said Ed Hinojosa Jr., president and chief executive of Opportunity Home, the city’s housing authority. Today, it’s 95,000.

“The need has never been as high as it is now,” Mr. Hinojosa said. “And with the trends we’re seeing, it’s just going to keep growing.”

In California, the state housing agency created an accelerator program in the pandemic to help cover some funding gaps, while the Legislature has passed more than 100 laws since 2016 to loosen restrictive zoning. The mayor of Los Angeles, Karen Bass, vowed to cut red tape for affordable housing projects.

Florida, which has seen an enormous influx of residents, in March passed the $710 million Live Local Act, a hybrid package of funding and zoning initiatives to catalyze affordable-home construction and usurp some local power to block developments.

The need for such homes is crucial, especially in markets with a large work force of hourly hospitality workers, said Ryan von Weller of Wendover Housing Partners, who advised legislators fashioning Live Local.

“You’re never going to be able to get your head above water with this issue, but you have to do something,” he said. “Watching things continue to slide downhill is not an option.”

Developers expect markets to eventually normalize, making it easier to obtain financing, and some have suggested that the cooling of other real estate sectors, such as offices, will free up construction labor. But few see any hope that production will ramp up in a way that significantly narrows the supply gap anytime soon.

Perhaps the best case for optimism comes from the realization of the depths of the problem: The scale of need has brought Republican and Democratic politicians together in a shared sense of a crisis, said Ms. Yentel, the National Low Income Housing Coalition president. Two bipartisan bills have been introduced in the House of Representatives to create or preserve 1.5 million affordable homes in the next decade.