SACRAMENTO — All single-stall public bathrooms in California must be open to “all genders” starting Wednesday under a state law passed last year to expand the rights of transgender people.

The new law, by Assemblyman Phil Ting, D-San Francisco, requires businesses, government buildings and other public places to make single-stall bathrooms open to all genders, instead of one for men and another for women. The requirement would become part of code enforcement inspections and does not affect multi-stall restrooms.

For A.T. Furuya, a 34-year-old from San Diego who identifies as nonbinary, the new law will ease the anxiety of having to choose between the men’s or women’s restroom.

“I just need to pee, but I have to mentally prepare myself for people yelling at me or judging me or making me feel uncomfortable,” Furuya said. “When I see an all-gender bathroom, I know I can enter and exit and that I have rights. You can’t question it. My gender won’t be up for debate and policing by other people.”

California already has the most inclusive restroom-access laws in the country, which include a law passed in 2013 that allows transgender K-12 students to use the school restroom corresponding with the gender identity they choose.

Supporters of the state’s newest law said it benefits not only transgender people but also parents who have children of the opposite gender when accompanying them to the restroom.

The law takes effect as lawmakers in other states seek restrictions on which bathroom a transgender person can use.

“I think it’s horrible that people want to make bathrooms political,” Ting said. “It’s something we all need. We shouldn’t have to worry about being harassed or beaten up going into a bathroom. In California, we have a sensible policy. It’s unfortunate to see other states in the country going backward.”

Lawmakers in more than a dozen states have introduced bills this year that limit transgender people’s access to the public restroom that corresponds to their gender identity, but so far several of those attempts have fallen flat. Transgender and gender nonconforming advocates say those bills are receiving backlash from the North Carolina law approved last year that requires transgender people to use the bathroom that corresponds to the gender on their birth certificate. North Carolina’s restrictive bathroom law cost the state millions after major corporations left, entertainers canceled concerts, the NCAA pulled championship events and the NBA All-Star Game was moved from Charlotte to New Orleans.

“We are definitely seeing more of these bills go down with the help of transgender youth who are at the forefront of humanizing our community,” said Sasha Buchert, a staff attorney at the Transgender Law Center.

Still, some efforts to create further restrictions could be buoyed by the Trump administration’s decision in February to revoke U.S. transgender guidelines that allowed students to use the bathroom and locker room matching their gender identities.

“There is a lot of fear around restroom access and being inclusive in those spaces, so having California set this example will show those are unfounded,” said Jo Michael, legislative manager at Equality California.

Melody Gutierrez is a San Francisco Chronicle staff writer. Email: mgutierrez@sfchronicle.com. Twitter: @MelodyGutierrez