Eight bodies were recovered off Tunisia after security forces clashed with a group of people on a boat attempting to cross illegally to Italy, a security official said on Sunday.

National Guard spokesman Colonel Houssemeddine Jebabli told AFP that eight bodies had been found since the incident on Friday, but their nationalities had not yet been determined and a search would continue.

The police intervened to stop the boat that had been launched from the central city of Sfax. People on the vessel threw Molotov cocktails at security forces before setting fire to the boat and attempting to flee, Jebabli said.

Tunisia has become a major route for people trafficking in recent months as migration from Africa to Europe via Libya proves increasingly difficult amid a crackdown by the Libyan coast guard and armed groups.

Jebabli said four Tunisians were arrested along with eight migrants from the Ivory Coast and two from Congo, adding that one was hospitalised with burns.

As the economy struggles, an increasing number of Tunisians are embarking on risky journeys across the Mediterranean to seek work and a better life in Europe.

In June, Tunisia's Interior Minister Lotfi Brahem was dismissed from his position, days after more than 100 people died when their boat sank off the coast.

The government gave no reason for the sacking of Brahem, but an official speaking to Reuters on condition of anonymity said that Prime Minister Youssef Chahed “fired the interior minister for failing to stop the boat and illegal boat migration in general".

In the first half of 2018, almost 2,660 people were arrested in Tunisia during attempts to make the sea crossing, Jebabli said, compared with 564 in the same period the previous year.