The head of Libya’s UN-backed unity government arrived Wednesday in Tripoli, but international hopes of a peaceful power handover were dealt a swift blow as the unrecognised authorities demanded his departure.

Fayez al-Sarraj, a businessman named prime minister-designate under a UN-brokered power-sharing deal in December, arrived by sea with a naval escort along with several members of his cabinet.

But in a sign of the formidable challenge facing Sarraj’s government, Tripoli’s unrecognised authorities demanded that he leave the capital or “hand himself in”.

“Those who entered illegally and secretly must surrender or turn back,” the head of the Tripoli authorities Khalifa Ghweil said in a televised address. “We won’t leave Tripoli as long as we are not sure of the fate of our homeland.”

Tripoli’s government had declared a state of emergency ahead of Sarraj’s anticipated arrival, and several main highways were blocked late Wednesday by armed groups — some uniformed and others in civilian clothes — who arrived aboard military vehicles, an AFP reporter said.

Residents hurried to their homes as cracks of gunfire could be heard around the capital.

Libya has had two rival administrations since mid-2014 when a militia alliance overran the capital, setting up its own authority and forcing the internationally recognised parliament to flee to the country’s remote east.

International leaders, increasingly alarmed by the rise of jihadists and people-smugglers in the impoverished North African state, have urged Libya’s political rivals to support the unity government.

But so far the two administrations have refused to cede power.

A presidential council formed under the December deal confirmed on its Facebook page that Sarraj and several other members had “arrived safe and sound in Tripoli”.

Sarraj said he would make “reconciliation and the settlement of security and economic crises” his top priority.

UN special envoy Martin Kobler joined a string of Western officials in hailing Sarraj’s arrival, urging a “peaceful and orderly handover of power”.

– ‘Unique opportunity’ –

The EU’s foreign affairs chief Federica Mogherini said Sarraj’s arrival in the capital was “a unique opportunity for Libyans of all factions to reunite”.

She added that the 28-nation European Union stood ready to support Libya and had already prepared an aid package worth 100 million euros ($110 million) for various projects.

Italy, which has offered to lead a peacekeeping force in Libya if asked to by the new government, also welcomed the development.

“It is another step forward for the stabilisation of Libya,” Foreign Minister Paolo Gentiloni said.

Sarraj and his cabinet had previously been blocked from entering the capital by the authorities there, who even closed the airspace several times to prevent them flying in.

Tripoli residents reacted on social media to Farraj’s arrival with a mixture of hope and sarcasm.

Twitter user @alladdinno said Sarraj’s appearance in the capital “felt like when the things you ordered online finally arrive”.

– ISIS high priority –

The unity government announced this month that it would start working on the back of a petition signed by a narrow majority of Libya’s elected lawmakers.

The United States and its European allies have threatened sanctions against those who undermine the political process.

Libya has descended into chaos since the 2011 ouster of longtime dictator Muammar Gaddafi, raising fears the Islamic State group is establishing a new stronghold just across the Mediterranean.

ISIS has seized control of Kadhafi’s coastal hometown of Sirte and launched a wave of attacks, both against rival Libyan forces and across the border in Tunisia.

Western countries are considering military action against the jihadists in Libya but want a unity government to request help first.

The US Special envoy for Libya Jonathan Winer tweeted that the country’s politicians “must now begin crucial work to address full range of #Libya’s challenges”.

Libya has long been a stepping stone for migrants seeking to cross the Mediterranean to Europe, which lies just 300 kilometres (185 miles) away, and in recent years traffickers have exploited the country’s instability.

Libyan coastguards rescued 152 Europe-bound migrants from two vessels in trouble early on Wednesday, according to a spokesman for the Tripoli navy.

Around 330,000 migrants have landed in Italy from Libya since the start of 2014.