The aircraft crashed in a field on the edge of the village of Nianou, around 40 kilometres (25 miles) from the capital, but managed to avoid any houses, an AFP journalist reported.
The Libyan flag was still visible on the tailplane amid the charred wreckage of the aircraft.
“The plane crashed at 1:30 am (0030 GMT)… with 11 people on board — three doctors, two patients and six crew members,” emergency services spokesman Mongi El Kadhi said.
“The whole plane was completely burnt out. The emergency services went to the crash site and recovered the charred bodies.”
There was no immediate word on the identities of the two patients on board or why they were being flown to Tunis-Carthage international airport from a military airfield near Tripoli.
Tunis air traffic control official Sofiene Bejaoui said the aircraft was a Soviet-designed twin-propeller Antonov-26.
“According to the air traffic controller who spoke to him last, the pilot’s final message was ‘Engine on fire’,” he said.
“The plane is a Libyan air force Antonov-26, registration number Five Alpha Delta Oscar Whiskey,” Bejaoui said.
Nearly 1,400 of the military transport aircraft were built between 1969 and 1986, 420 of them for export, according to the manufacturer’s website.
At daybreak, teams began searching for the aircraft’s black box flight recorders in a bid to establish the cause of the apparent engine failure.