A federal judge blocked a California law requiring background checks for every ammunition purchase on Thursday.

District Court judge Roger Benitez blocked the state from enforcing the law, which was passed in a 2016 ballot initiative and went into effect in July 2019. Benitez called the restrictions "onerous and convoluted" with a high rate of false-positives that violated the Second Amendment rights of Californians, as well as running afoul of the commerce clause.

"The experiment has been tried. The casualties have been counted," Benitez wrote. "California’s new ammunition background check law misfires and the Second Amendment rights of California citizens have been gravely injured."

The ruling dealt a blow to one of the strictest gun-control measures in the country and could provide new clarity on the extent to which voters and state governments can curtail gun rights.

The case was filed by NRA affiliate the California Rifle and Pistol Association (CRPA) and three-time Olympic gold medalist Kim Rhode. They claimed the state's ban on carrying ammunition across state lines, coupled with the requirement that all sales be subject to a background check—unlike most other states which only require checks for gun sales—made it far more difficult to legally purchase ammunition in the state. The system had a 16.4 percent false-positive rate with an appeals process that forced residents to wait months to correct those problems. The National Rifle Association, which helped fund the suit, celebrated the ruling.

"California wasn't just obstructing the people's fundamental right to defend their families and lives—it was encouraging unlawful hostility toward an individual, Constitutional right," Jason Ouimet, executive director of the NRA's Institute for Legislative Action, said in a statement. "The NRA funded this case for the same reason the court struck down the laws: enough was enough."

The ammunition law was passed via ballot initiative Proposition 63 in 2016. Judge Benitez said he was "mindful" of the will of the majority of voters, but said "the Constitution remains a shield from the tyranny of the majority."

"Law-abiding citizens are imbued with the unalienable right to keep and bear firearms along with the ammunition to make their firearms work," he wrote. "That a majority today may wish it were otherwise, does not change the Constitutional right. It never has."

Chuck Michel, CRPA president and general counsel, said the ruling dealt a "devastating blow to the anti-gun-owner advocates who falsely pushed Prop 63 in the name of safety."*

"Red tape and the state’s disastrous database errors made it impossible for hundreds of thousands of law-abiding Californians to purchase ammunition for sport or self-defense. The Court found that the flimsy reasons offered by the government to justify these Constitutional infringements were woefully inadequate." he said in an email. "While we expect the state to appeal this ruling, Californians can sleep a little easier tonight knowing their Constitutional rights were restored and strengthened by this decision."

Benitez drew on the current coronavirus emergency in his ruling.

"Presently, California and many other states sit in isolation under pandemic-inspired stay-at-home orders," he wrote. "Schools, parks, beaches, and countless non-essential businesses are closed. Courts are limping by while police make arrests for only the more serious crimes. Maintaining Second Amendment rights are especially important in times like these. Keeping vigilant is necessary in both bad times and good, for if we let these rights lapse in the good times, they might never be recovered in time to resist the next appearance of criminals, terrorists, or tyrants."

The office of California attorney general Xavier Becerra said it is "reviewing the decision," as it weighs a potential appeal.

*This piece has been updated with comment from the CRPA