UAE officials on Saturday deported former Egyptian premier and presidential hopeful Ahmed Shafiq from the Gulf country he had been living in since 2012 to Egypt after he announced his candidacy in upcoming elections, two of his aides told AFP.

Shafiq landed in Cairo airport on Saturday evening and quickly left to an unknown destination, an airport official said.

The move comes days after Shafiq, in exile in the UAE since 2012, announced his candidacy in next year's election and then said he was being prevented from leaving the country, angering his Emirati hosts.

The UAE state news agency WAM had reported that Shafiq left the country for Egypt, while his family stayed behind, but did not mention that he had been deported.

Shafiq, a former army general appointed as prime minister by Hosni Mubarak, had narrowly lost an election to Islamist president Mohamed Morsi in 2012, a year after Mubarak's overthrow.

He was placed on trial after the polls on corruption charges and acquitted, and one of Shafiq's lawyers said last year that he was free to return to Egypt.

One aide said she witnessed officials arriving at his Abu Dhabi house and was told that Shafiq, seen as a main challenger to President Abdel Fattah al-Sisi, would be deported to Egypt on a private plane.