Beginning in March, all single-occupancy public restrooms in the state must be open to all genders. California is the first state with such a law.

California today became the first state in the nation to adopt legislation requiring that all single-occupancy restrooms in California businesses, government buildings, and other places of public accommodation be open to all genders.

Gov. Jerry Brown today signed the legislation, Assembly Bill 1732, into law, as it had been approved by both the state Assembly and Senate. It will take effect March 1, giving the Golden State “the nation’s most progressive restroom access law,” notes a press release from the Transgender Law Center.

Several cities have such laws, according to the legal group, including Philadelphia, Austin, Seattle, San Francisco, New York City, Washington, D.C., and Santa Fe, N.M. Many colleges and universities, including the University of California system, also have similar policies, and some private businesses have put inclusive measures in place — management of the Sacramento Kings NBA team recently announced that the team’s new stadium, the Golden 1 Center, will include all-gender restrooms, and Target is putting gender-neutral facilities in all its stores. But California has the first statewide law.

“California is charting a new course for equality,” Assemblyman Phil Ting, the bill’s author, said in the press release. “Restricting access to single-user restrooms by gender defies common sense and disproportionately burdens the LGBT community, women, and parents or caretakers of dependents of the opposite gender. Bathroom access is a biological need. This law will ensure more safety, fairness, and convenience … for everyone.”

The legislation won praise from activists for transgender equality and women’s rights. “This law is a simple measure that will make everyone’s lives easier,” said Kris Hayashi, executive director of the Transgender Law Center. “Having restrooms open to all genders will mean less hassle for everyone going about their day and will allow people who don’t fit neatly into expectations of what it looks like to be male or female to use the restroom without fear of harassment.”

One such person, Sara Rosenfeld, had spoken at a press conference in support of the legislation and commented further in the law group’s press release. “For my whole life, public restrooms have been places of fear, anxiety, and danger for me — just because I don’t fit people’s expectations of what a woman should look like,” said Sara Rosenfeld, a 44-year-old Berkeley resident. “As a queer, black, more masculine-looking woman, I am constantly questioned and harassed when I use the bathroom. AB 1732 is a simple but important law that would help cut down on the fear and harassment I face every day.”

Ting said there was some opposition to the bill from social conservatives, but the strongest objection came from people asserting that “men don’t seem to be able to use the bathroom without making a mess,” as he told Time. But restroom users will just have to avoid making messes, he added.

Businesses and governments won’t have to spend much to implement the law, Time reports. All they will have to do is change their signage, estimated to cost about $40 per restroom.

The bill had the support of the Transgender Law Center, LGBT group Equality California, and the California branch of the National Organization for Women.

The California measure contrasts starkly with North Carolina’s House Bill 2, passed in March, which bars transgender people from using the restrooms that match their gender identity, when those are located in government buildings, including public schools and state universities. North Carolina has seen a backlash over the law, with the NBA pulling its 2017 All-Star Game from the state and businesses canceling planned expansions. HB 2 also prevents cities and counties from adopting or enforcing LGBT-inclusive antidiscrimination ordinances or setting a minimum wage higher than the state’s.

Legislation aimed at restricting trans people’s restroom access was introduced in several other states this year and last without success. In March, South Dakota’s governor vetoed one that would have affected students in public schools, and a similar measure in Tennessee was withdrawn by its sponsor in April, although she vowed to bring it back next year. But more than 20 states are suing the U.S. Department of Education because of a guidance document — nonbinding — advising schools to let trans students use the restrooms and locker rooms appropriate for their gender identity.