"The bottom line is clear," Comey said. "Dylann Roof should not have been allowed to purchase the gun that day."
He said Roof went to a West Columbia, S.C., gun shop on April 11 to buy the gun. Under federal law, the FBI had three days to block the purchase.
But an FBI examiner in West Virginia failed to get notice of a March drug arrest of Roof that would have likely resulted in Roof being disqualified from purchasing the weapon.
On April 16, the gun dealer sold the weapon to Roof, who used it in the June 17 attack.
Comey said he has ordered a full review of the mistake and will make recommendations for improvements to background checks. He added that he was informed of the lapse Thursday night but that agents have been reviewing the matter for weeks.