Pakistan has launched a registration drive to document the estimated 1 million Afghan nationals who have been living in the country illegally since fleeing war and unrest in the 1980s.

Syed Jawad Hussain, the official in charge of a registration center near the eastern city of Peshawar, said the drive is aimed at encouraging Afghans to register with authorities or return to their homeland.

Those who do neither risk arrest, as Pakistan has ordered all Afghans living there illegally out by the end of the year. Those who register with the authorities can secure temporary permission to stay in Pakistan until the end of the year.

Pakistan is home to another 1.5 million refugees who have registered with the United Nations and are not at risk of expulsion.