Fifteen people have been killed by a teenage gunman who went on a rampage in south-west Germany, officials say.
Among the dead were nine pupils and three teachers at the Albertville secondary school in Winnenden, north of Stuttgart, police say.
The gunman, a 17-year-old former pupil, entered the school at about 0930 (0830 GMT) dressed in black combat gear and opened fire at random.
He fled in a stolen car, but was later killed in a shoot-out with police.
See where the school shooting took place
German Chancellor Angela Merkel described the shootings as "incomprehensible".
"It is unimaginable that in just seconds, pupils and teachers were killed - it is an appalling crime," she told reporters.
"This is a day of mourning for for the whole of Germany."
Officials earlier said a 10th pupil had died raising the death toll to 16, but this was later revised down to nine pupils.
'Trembling and crying'
Police said the suspect - named locally as Tim Kretschmer - was killed during a shoot-out with officers in the town of Wendlingen, about 40km (25 miles) away from the school.
He had fled there in a car he had hijacked after the school shooting - killing a passer-by as he made his escape, police said.
Spokeswoman Inka Buckmiller said the shoot-out took place at a car showroom, where two bystanders were killed and two police officers were injured.
"The suspect also died as a result of this shooting," she said.
Baden-Wuerttemburg state governor Guenther Oettinger said police killed the suspect, the Associated Press reported.
In total, 10 students, three teachers and three passers-by are thought to be among the dead.
One woman said her daughter had been in the school at the time of the shooting, and she was now at home "trembling and crying".
"She and her friend jumped out of the window. Her friend is now in hospital... We hope that she's all right," the woman said.
"What can I say? I don't understand the world any more."