"There was a riot inside al-Kweifiya prison, as well as an attack from outside," a security official, speaking on condition of anonymity, told Iran's Press TV. "More than 1,000 prisoners escaped. Special forces called in as reinforcements were given orders not to fire at the prisoners."
The official said most of the fugitives had been imprisoned for common law offenses, though "some of them were detainees in cases linked to the former regime of Moammar Gadhafi."
However, a security official at the prison said most of the inmates who escaped were facing serious charges, Press TV reported.
Government security official Mohammed Hejazi said government forces recaptured 18 inmates some returned on their own.
Libyan Prime Minister Ali Zeidan said the breakout was orchestrated by area residents "because they don't want the prison near their homes."