(CNN) HIV prevention drugs will be available without a prescription starting next year in California under a bill signed Monday by the state's Democratic governor.

The medications covered by the new legislation are pre-exposure prophylaxis (PrEP) and post-exposure prophylaxis (PEP), which both help prevent HIV infections.

The state will be the first in the country to allow pharmacists to provide the drugs without a physician's prescription, nonprofit organization Equality California said. The law takes effect January 1.

"The HIV epidemic is still a pressing issue today -- especially for LGBTQ people of color and folks in rural communities," the group's executive director, Rick Zbur, said.

Gov. Gavin Newsom's signature, he said , is a "giant step forward in getting to zero transmissions, zero deaths and zero stigma."

Read More