Sarah Leah Whitson, director of Middle East and North African programs at Human Rights Watch, said Libya's transitional leaders missed the July 12 deadline to take custody of Libyans who supported the former regime of Moammar Gadhafi during last year's civil war.
"Across Libya, thousands of detainees still languish in prisons run by militias, without a formal charge and without any prospect for legal review," she said in a statement.
Human Rights Watch said it believed most of the prisoners were guards, mercenaries and members of the national security forces. Many of them, the group said, were subjected to extensive torture while held in detention facilities run by militias.
Fred Abrahams, a special adviser at Human Rights Watch, has said torture and illegal detention are "an ongoing national crisis" for post-war Libya.
Members of the former regime, including Gadhafi's son Saif al-Islam, are suspected of committing war crimes during last year's civil war.
The International Committee of the Red Cross last week met with Libyan leaders to brief them on international laws related to detainees held in connection with last year's civil war.
Gal Gadot cast as Wonder Woman for 'Batman vs. Superman'
Couple mistakenly served bag of cash at McDonald's drive-thru