Unidentified war planes attacked targets in Libya's capital Tripoli on Sunday, hours after forces from the city of Misrata said they had seized the main airport.

Tripoli residents heard jets followed by explosions at dawn but no more details were immediately available.

In recent weeks Libya has seen the worst fighting since the NATO-backed campaign to oust Muammar Gaddafi in 2011. Renegade general Khalifa Haftar has declared war on Islamist-leaning forces, part of growing anarchy in the oil producer.

His forces claimed responsibility for air raids on Tripoli on Saturday and last Monday, targeting a group called Operation Dawn. But this group, consisting mainly of fighters from Misrata, said on Saturday that it had captured Tripoli's main airport from a rival faction from Zintan in western Libya.

In the campaign to overthrow Gaddafi, fighters from Zintan and Misrata were comrades-in-arms. But they later fell out and this year have turned parts of Tripoli into a battlefield.

Libya's neighbours and Western power worry Libya will turn into a failed state as the weak government is unable to control armed factions.

GROWING DIVISIONS

Libya faces the prospect of two competing parliaments, after the claimed Misrata victory at Tripoli airport which Reuters could not immediately confirm.

In a challenge to the parliament elected on June 25, a spokesman for Operation Dawn called for the old General National Congress (GNC) to be reinstated. Misrata forces have rejected the new House of Representatives, where liberals and lawmakers campaigning for a federalist system have made a strong showing.

In a sign of deep divisions between Libya's regions and political factions the House of Representative declared the Operation Dawn as well as militant Islamists like the Ansar al-Sharia as "terrorist groups".

The House of Representatives, which has fled to Tobruk in the east with senior officials to escape fighting, asked renegade general Haftar to fight the Operation Dawn forces.

Haftar launched a campaign against Islamists in the eastern city of Benghazi in May and threw his weight behind the Zintan fighters.

His air defence commander, Sager al-Jouroushi, told Reuters on Saturday that his forces were responsible for the air strikes on Saturday and a similar attack on Monday.

Misrata forces have blamed the air strikes on Egypt and the United Arab Emirates. Libya's government says it does not know who is behind the attacks.

"This is a war between the Libyan state and the state institutions led by our sons, soldiers and officers in the army, against terrorist groups outside of the law," the House of Representatives said in a statement.

Fighting also erupted between Haftar's troops and allied army special forces with Islamists in two Benghazi suburbs on Saturday, killing eight soldiers and wounding 35, medics said.

The violence has prompted the United Nations and foreign embassies in Libya to evacuate their staff and citizens, and foreign airlines have largely stopped flying to Libya.

Libya's central government lacks a functioning national army and relies on militia for public security. But while these forces receive state salaries and wear uniforms, they report in practice to their own commanders and towns.