A 13-year-old girl was also seriously injured after the incident near Ulm.
A 14-year-old girl has died after being attacked by a man with a knife on her way to school, German police said.
Another teenage girl, aged 13, was also injured in the incident in a residential area of Illerkirchberg -- between Stuttgart and Munich -- on Monday morning.
Both girls were initially rushed to hospital, where the older girl later succumbed to her injuries.
The suspect reportedly fled into a nearby refugee centre where officers later detained three men, including the suspected attacker, a 27-year-old Eritrean man.
Investigators have found no evidence of a religious or political motive for the attack, a senior German security official said on Tuesday.
“I grieve with the girl who was killed and fervently hope that the injured recovers her health,” German Interior Minister Nancy Faeser wrote on Twitter. “My thoughts are with their families at this time.”
German police have urged the public to refrain from stoking suspicion against refugees, asylum-seekers, and other foreigners.
The girl who died had family roots in Turkey, and Turkey’s ambassador in Germany visited her family in Illerkirchberg on Tuesday to offer his condolences.