Samihullah knew it was time to leave the country of his birth when insults were hurled at him in the bazaar.
A tailor from a family of Afghan refugees, Samihullah was raised in the northern Pakistani town of Mansehra but never gained citizenship and was always considered an Afghan.
As tensions between the nuclear-armed rivals India and Pakistan have grown in recent months, Samihullah has faced harassment in Mansehra’s streets for Kabul’s deepening ties with New Delhi.
"Afghans used to be called 'Kabuli' in Pakistan, but now Pakistanis call them 'Hindus' because we signed economic agreements with India," Samihullah said. Like many Afghans, he goes by just one name.
The 32-year-old recently moved back to Afghanistan with his two wives, one Afghan and one Pakistani.
"They said we chose India's friendship, so we should go to India. We were hiding in our shops and homes to avoid being arrested," Samihullah recalled from his last few months in Pakistan.
Even before the latest clashes between Indian and Pakistani forces in the disputed Kashmir region, the climate in Pakistan was more hostile for Afghan refugees. An estimated 3 million Afghan refugees, half of them registered and the rest undocumented, faced police harassment and deportations.
But the pressure has increased dramatically as Afghan-Indian relations have strengthened and those between New Delhi and Islamabad -- and Pakistan and Afghanistan -- have deteriorated.
This resulted in tens of thousands of Afghan refugees to return to their country. Many like Samilullah are now housed in a temporary refugee center near Kabul.
"These people were our guests, we kept them in our house. Afghanistan should be grateful to us," said a Pakistani Army official based in the southern city of Quetta. "Instead it ... has become buddies with India. It's like stabbing us in the back."
The treatment of Afghan refugees in Pakistan illustrates how gravely diplomatic tensions have affected them, forcing many to have to start again from scratch.
"It will take a big adjustment," said Maya Ameratunga, country director for UNHCR in Kabul. “These returnees are coming back after more than three decades in exile."
UNHCR provides $400 in cash and some medical and emergency assistance to every returning refugee family. But international funds are drying up in the face of a series of global crises.
The prospect of reintegration into a country many refugees never knew as home is a tall order and is even proving impossible for some.
"Some people are able to go to live with relatives, but others may not have that possibility. So unfortunately what we are seeing is people becoming displaced," Ameratunga added.
Afghan refugees, some of whom have lived in Pakistan for nearly four decades, have periodically suffered because of deteriorating relations between Kabul and Islamabad. Since 2001, ties between the two neighbors have been clouded by mutual accusations that militant extremists find shelter on the other side of the border.
Pakistani officials, however, deny that Afghan refugees face systematic harassment in their country.
"We want them to return home in peace with honor and dignity," said Akhtar Munir, a spokesman for the Pakistani Embassy in Kabul. He emphasized that there was no connection between India and the repatriation of Afghan refugees and.
The number of assisted returns jumped from 1,433 in June to 11,416 in July and 60,743 in August. More than 90,000 refugees have been returned to Afghanistan so far this year, almost all from Pakistan, and the number is expected to pass 220,000 for the year, according to figures compiled by UNHCR.
-- With reporting by Reuters