"The government is very relieved that a German national who was kidnapped more than two years ago in Pakistan has been freed in Afghanistan," a foreign ministry spokeswoman told AFP.
He was now in the care of the German government, receiving counselling and was "doing well under the circumstances", said the spokeswoman, adding that an international "partner" had helped set him free.
Newspaper Bild said that Germany's KSK special forces were involved in the handover of the aid worker for the group Welthungerhilfe (World Hunger Aid), who was identified only as Bernd M.