ISIS has claimed responsibility for a "slaughterhouse" knife and axe attack that left four people severely injured on a commuter train in the German city of Wurzburg.

The terror group's propaganda arm Amaq this morning claimed the unnamed 17-year-old Afghan assailant was one of its fighters.

Police had earlier found a hand-painted ISIS flag in his bedroom and note that indicated he had become self-radicalised.

Two of those injured are in a critical condition.

12 Inside . . . floor of the train carriage covered with blood and emergency blankets. Four were severely injured during the attack Credit: AP:Associated Press

12 The teenage attacker was shot dead by police. They later discovered an ISIS flag in the assailant's bedroom Credit: DPA

12 Axe attack . . . the horrific nature of the attack was made clear by picture showing blood covering the floor of the commuter train Credit: DPA

A statement from the terror group read: "The perpetrator of the stabbing attack in Germany was one of the fighters of the Islamic State and carried out the operation in answer to the calls to target the countries of the coalition fighting the Islamic State."

Carriages of a commuter train were left looking "like a slaughterhouse" after the teenage refugee attacked train passengers - who hailed from Hong Kong.

Survivors are being treated by trauma counsellors after witnessing the attack and the axeman being shot dead by police marksmen as he tried to flee the scene.

One witness, who went to the train from her nearby home to help out after it stopped on a stretch of line in Bavaria, said: "I have never seen so much blood in my life.

"I will not sleep tonight."

Horrified survivors leaped from the train screaming for bandages to help the three severely wounded, who are all members of the same family from Hong Kong, inside.

The 17-year-old attacker shouted “Allahu Akbar” (God is great) during the attack, according to a Bavarian interior ministry spokesman, who added: “It is quite probable that this was an Islamist attack.”

Minister Joachim Herrmann said the boy had come to Germany from Afghanistan as an unaccompanied refugee.

A dad, 62, his wife, 58, their 27-year-old daughter and her boyfriend, 31, were all targeted in the attack. The couple's 17-year-old son was uninjured.

Three of the four victims are fighting for their lives, one is less seriously hurt and 14 other passengers are in severe shock.

12 The attacker is now confirmed to have been shot dead by police Credit: DPA

12 The incident took place between Ochsenfurt and Wuerzburg-Heidingsfeld train stations at around 9.15pm local time Credit: DPA

12 The train line between Wurzburg-Heidingsfeld and Ochsenfurt has now been closed Credit: DPA

12 The attack is not as bad as initially feared, with local media originally reporting up to 21 people wounded Credit: DPA

12 14 of the people who were thought to have been physically hurt were in fact being treated for shock Credit: AP:Associated Press

Police said the dad and son were badly hacked a with the knife as they tried to fight the attacker off.

Local media reported that up to 20 people had been attacked on the train in the Heidingsfeld district of Wurzburg in Bavaria, southern Germany, at about 9.15pm local time.

Grim images printed in German newspapers showed lino-covered floors of the regional train from Treuchtlingen to Wurzberg awash with blood.

The carriage was left awash with blood and filled with abandoned belongings.

Police said three commuters were critically injured, another suffered minor wounds, and 14 more were treated for shock. The attacker was chased by cops after fleeing the train.

German TV said the Afghan boy had lived as an asylum-seeker with a foster family in the Ochsenfurt district.

He was supported by the local Kolpingwerk society, an international Catholic charity.

12 The attack happened in the Bavarian city of Würzburg - located between Frankfurt and Nuremburg Credit: Google Maps

12 Emergency services were pictured arriving on the scene in images posted on social media

12 Four people were wounded in the attack, which is now believed to have been motivated by radical Islam Credit: Twitter

12 The incident comes just days after the devastating terror attack in Nice where 84 were killed Credit: DPA

He is said to have arrived in Germany this year and had been living with foster carers for two weeks after being housed in a refugee camp.

Local media said he boarded the train at his local station in Ochsenfurt, and cops said they believe he acted alone.

Shortly before news of the attack broke, Chancellor Angela Merkel’s spokesman had tweeted about the importance of successfully integrating refugees into the country.

A Foreign Office spokesman said: “We’re aware of an incident and are seeking further information.”

The incident comes just days after the devastating attack in Nice in which 84 people lost their lives, fuelling fears it could be another terror attack.

Evil fanatic Mohamed Lahouaiej-Bouhlel ploughed a lorry through crowds of revellers watching a firework display to celebrate France's national day.

ISIS later claimed responsibility for the attack, although some have suggested Bouhlel was simply mentally unstable.

We pay for your stories! Do you have a story for The Sun Online news team? Email us at tips@the-sun.co.uk or call 0207 782 4368