California governor Jerry Brown has signed a bill that imposes one of the strictest school vaccination laws in the US.
It would require most schoolchildren to be vaccinated against diseases including measles and whooping cough.
The bill has faced fierce criticism from some who say parents should decide whether their children are vaccinated.
The move comes after an outbreak of measles at Disneyland in 2014 infected over 100 people in the US and Mexico.
Only children with serious health issues would qualify for exemption from the new measures. Unvaccinated children would have to be home-schooled.
Mississippi and West Virginia are the only other two states with such strict requirements.
Parents opposed to the bill have vowed to take legal action, even though the issue has been upheld in court, including by the Supreme Court.
They argue that some vaccines are unsafe and claim the legislation is eliminating informed consent and trampling on parental rights.
"The science is clear that vaccines dramatically protect children against a number of infectious and dangerous diseases," Mr Brown said in a statement on Tuesday.
"While it's true that no medical intervention is without risk, the evidence shows that immunisation powerfully benefits and protects the community."