The attack, which left the 35-year-old teacher with an injured shoulder and hand, occurred in broad daylight in the south of the city, prosecutor Brice Robin said.
The 15-year-old ethnic Kurd rushed the victim from behind and stabbed him in the shoulder, then chased after him for a few metres until he fell, Robin said.
The victim, who was wearing a kippa at the time, fended off the assailant using his arms and legs, as well as his “holy book”, which was damaged in the scuffle, the prosecutor said.
The teen dropped his weapon (pictured below) at the scene of the attack before fleeing on foot. He was captured by authorities ten minutes later.
The teen yelled “Allahu Akbar” (God is greatest) during the attack, the Marseille branch of the Representative Council of Jewish Institutions in France (CRIF) told Metro newspaper.
The suspect “has the profile of someone who was radicalised on the Internet,” Robin told a press briefing.
“He claimed to have been acting for Daesh,” Robin said, using the Arabic acronym for the Islamic State group.
“You get the sense that he does not have a full grasp of the fundamentals of Islam,” he added.
The boy even admitted to investigators that he planned to arm himself and kill police as soon as he is released.
The prosecutor said the teenager's family was unaware of his radicalisation and that he was a “good student”.
“It appears there was a form of premeditation” with the intent of killing the victim because of his religion, Robin said.
The teenager, who will turn 16 next week, faces charges of “attempted murder on grounds of religion” and “defence of terrorism”.
Prime Minister Manuel Valls reacted with a tweet saying: “The anti-Semitic aggression against a teacher in Marseille is revolting.”
Interior Minister Bernard Cazeneuve called the incident a “revolting anti-Semitic attack” on his Twitter account. He added that an investigation was underway.
The attack marks the latest in a long line of anti-Semitic incidents in France over the past twelve months. The most prolific of these was the January terror attacks almost exactly a year ago, when four people were killed inside a Jewish supermarket in eastern Paris.
There have even been other recent anti-Semitic attacks in Marseille, most recently when another teacher was stabbed by three attackers who shouted support for Isis after the attack.
The growing insecurity in France's Jewish community has pushed many to make “aliyah” and emigrate to Israel, with record departures in 2015 of 7,900 people, according to official figures. Although there are numerous reasons, more than just security fears, to explain the exodus.