Construction workers work on a home at a housing development in Novato. Justin Sullivan/TNS

As cities across California try to avoid complying with new state housing laws, Attorney General Rob Bonta is asking state legislators to give him another tool to rein in scofflaw municipalities.

Bonta’s office is sponsoring a bill that would give the attorney general the unconditional right to wade into any lawsuit filed over a potential violation of state housing law.

The measure, Assembly Bill 1485 by Matt Haney, D-San Francisco, comes as Bonta has increasingly sought to expand the state’s role in enforcing housing laws as California falls deeper into a housing shortage. Bonta’s work is only expected to grow as cities face aggressive state-mandated targets to build far more units by 2031.

Haney said while some cities have been good actors, there are numerous localities where NIMBY (Not in My Backyard) politics motivates local officials to make it too burdensome to approve new housing in existing neighborhoods.

“There are localities all across the state, unfortunately, who are trying to make their areas no-new-housing zones,” Haney said. “And that’s a violation of state law. The attorney general has to have the tools to combat that.”

Two years ago, Bonta’s office created a Housing Strike Force. It’s a special division within his office that’s designed to hold cities accountable for skirting laws the Legislature has passed in recent years to fast-track some local processes that are often used to fight denser housing, including planning, zoning and permitting approvals.

But housing advocates and the attorney general’s office said the office has sometimes been constrained or delayed in its ability to intervene in lawsuits challenging roadblocks to proposed housing.

For example, in October, Bonta’s office requested to intervene in a lawsuit against the city of Anaheim after it denied a permit for a project to convert existing housing into a transitional home for formerly homeless women. Nearly six months later, the judge still hasn’t decided whether to allow the state to join the case.

That’s because, under current state law, the attorney general needs to get a judge’s permission to intervene in a third-party lawsuit filed to challenge a potential violation of state housing law. Haney said that has delayed Bonta’s involvement for months in some cases — and could allow judges to block him outright.

AB1485, which Haney plans to unveil Tuesday, was written in partnership with Bonta’s office and the Housing Action Coalition, an advocacy group frustrated by cities’ attempts to block new housing laws.

While the attorney general already has the ability to file lawsuits against cities that violate housing law under a public right of action, many housing lawsuits in the state have come from YIMBY (Yes in My Backyard) groups. Housing activists said such cases filed under a private right of action are needed because Bonta’s office alone cannot police the sheer volume of violations.

Todd David, special projects director for the Housing Action Coalition, said it’s important for Bonta to be able to easily intervene in those lawsuits because he can be more strident in confronting cities than developers, who are often fearful of having their projects stymied further.

“This is another tool that indicates to recalcitrant municipalities that the state is really concerned about this issue,” David said of AB1485.

Housing advocates said they expect the number of lawsuits Bonta files to rapidly accelerate as the state tries to force cities to meet their housing targets. California must construct 180,000 units, including 80,000 affordable units, each year to keep pace with existing housing demand. The state is only constructing about 80,000 units per year.

“The attorney general is going to be more and more involved in implementing and enforcing state housing laws,” said state Sen. Scott Wiener, D-San Francisco, who is co-authoring the bill with Haney. “That’s a big, powerful message that when we pass a state housing law, it’s not a suggestion, it’s a requirement.”

Wiener said the attorney general’s intervention in private lawsuits is also crucial because developers who file lawsuits are typically fighting for a specific project. He said Bonta has a broader public interest to protect the enforcement of state housing policy and to prevent a patchwork of legal interpretations that could be harmful.

Bonta echoed that sentiment in a statement, saying his office wants to easily wade into cases where the enforcement of housing law is a statewide concern. He said the bill would “maximize” his efforts to fight for better access to affordable units.

“Ensuring that all Californians have access to affordable housing is a top priority for my office, and we’ve been actively working to enforce state housing laws and address our housing crisis,” Bonta said.

Reach Dustin Gardiner: dustin.gardiner@sfchronicle.com; Twitter: @dustingardiner