Heavy gunfire broke out in the Libyan capital Tripoli on Saturday after two rival armed groups clashed in the city, witnesses said.

It was not immediately clear what triggered the fighting between the Zawiyat Addahmani area and Bab Azizziya or which groups were involved.

Several quasi-official groups operate as law enforcement and armed forces in Tripoli controlling different districts and clashes sometimes occur over territory or personal disputes.

Tripoli has been under control of an armed alliance called Libya Dawn since 2014 when its forces drove rivals out of the city, set up their own government and reinstated the former parliament as part of power struggle for control.