Get breaking news alerts and special reports. The news and stories that matter, delivered weekday mornings.

SAN DIEGO - A federal judge Thursday blocked background checks for ammunition buyers in California, calling the state's law on the matter "onerous and convoluted."

San Diego-based U.S. District Judge Roger Benitez granted a preliminary injunction against the rule after plaintiffs, including the California Rifle and Pistol Association and six-time Olympic medalist skeet shooter Kim Rhode, sued the state.

In 2016, Golden State voters approved Proposition 63, which included the background checks as well as a ban on high-capacity magazines for firearms. The same judge halted sales of the magazines as the state appeals another court challenge.

Let our news meet your inbox. The news and stories that matters, delivered weekday mornings. This site is protected by recaptcha

But in this case, Benitez was unequivocal.

"California’s new ammunition background check law misfires, and the Second Amendment rights of California citizens have been gravely injured," he wrote. "In this action, Plaintiffs seek a preliminary injunction enjoining California’s onerous and convoluted new laws requiring ammunition purchase background checks and implementing ammunition anti-importation laws."

The judge argued that the checks hurt legal ammo buyers while doing little to prevent criminals from obtaining firepower. "Criminals, tyrants and terrorists don’t do background checks," Benitez wrote.

California Attorney General Xavier Becerra late Friday filed an emergency motion with the U.S. Court of Appeals for the Ninth Circuit to pause Benitez's ruling while he appeals.

The background checks went into effect in July, making California the first state to implement such a process. New York enacted ammunition screening in 2013 but it never went into effect. Four states -- Connecticut, Illinois, Massachusetts and New Jersey -- vet ammo sales through licensing.

"This is a devastating blow to the anti-gun-owner advocates who falsely pushed Prop 63 in the name of safety," California Rifle and Pistol Association president Chuck Michel said in a statement. "In truth, 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 nonprofit Brady: United Against Gun Violence said it would support an appeal and called the decision "unprecedented."

"This decision is patently wrong, and we expect that it will be reversed on appeal," Brady president Kris Brown said in a statement. "The Second Amendment does not provide felons or domestic abusers with the right to buy ammunition or firearms, and it does not prevent states like California from requiring background checks."