The Sunnyvale City Council has voted unanimously to raise the age to buy an assault-style weapon to 21 except for active duty military members and law enforcement officials.
Sunnyvale Mayor Glenn Hendricks said the decision comes as the South Bay city strives to prevent a tragedy such as last month's deadly high school shooting in South Florida.
"You have to be 21 to drink," he said. "If youβre a teenager and you get your license, you have to wait 12 months before you can go ahead and drive with your friends so there's other things along the line of taking a look and we've seen that putting regulations in place for youth is not an inappropriate thing to do."
Sunnyvale has been on the forefront of gun regulations before, banning high-capacity magazines back in 2013.
According to the nonpartisan and nonprofit organization Everytown for Gun Safety, there have been 156 mass shootings since 2009. Those shootings were defined as four or more people being shot and killed, not counting the gunman.
Eleven mass shootings were carried out by men 21 years old or younger, according to the organization, and two of those gunmen used an assault rifle.