Taliban fighters captured the strategic city of Ghazni on Thursday, taking them to within 150 km (90 miles) of Kabul following days of fierce clashes as the terrorist group ruled out sharing power with the government based there.
The speed and violence of the Taliban advance has sparked anger among many Afghans over U.S. President Joe Biden's decision to withdraw U.S. troops and leave the government to fight alone.
"German nationals on the ground are strongly urged to take opportunities to leave the country on scheduled flights as soon as possible," the Foreign Ministry said on its website.
The defence minister on Monday rejected calls for Berlin to send soldiers back to Afghanistan after the insurgents took Kunduz, the city where German troops were deployed for a decade.
Germany had the second largest military contingent in Afghanistan after the United States, and lost more troops in combat in Kunduz than anywhere else since World War Two.