Pakistan handed over Gula and her four children to Afghan authorities at the shared border on Wednesday after she served a 15-day prison sentence. Gula pleaded guilty to living in Pakistan with fake identity documents.
"Pleased to have welcomed Sharbat Gula and her family back to Afghanistan," Ghani wrote on Twitter. "Her life inspires us all. She represents all the brave women of this land."
Gula was arrested in Peshawar, Pakistan, in late October during an identity-card fraud investigation. In February of 2015, she'd been accused of using fake information to get a Pakistani Computerized National Identity Card.
In 1984, Steve McCurry photographed Gula for National Geographic. She was 12 years old at the time and living in a refugee camp near Peshawar after she and her relatives fled Afghanistan after a Soviet airstrike killed her parents during the 1979-1989 Soviet-Afghan War. In 2002, McCurry tracked down Gula in Pakistan and managed to take another photograph of her.
Gula was also sentenced to pay a $1,100 fine.