PARIS — The suspect in the beheading of a history teacher in a Paris suburb was an 18-year-old immigrant of Chechen descent who was angered by the classroom display of caricatures of the Prophet Muhammad, French officials said on Saturday.
The suspect, identified by the authorities as Abdoulakh A., stalked the area outside the school on Friday afternoon before following the teacher, whom he stabbed and decapitated with a knife, Jean-François Ricard, the top antiterrorism prosecutor, said at a news conference.
“The individual was in front of the college in the afternoon and asked students to indicate the future victim to him,’’ Mr. Ricard said, referring to the middle school where the teacher had taught. The suspect was fatally shot by the police in a confrontation soon after the killing.
Investigators found a message planning the attack on the suspect’s cellphone, written a few hours before, Mr. Ricard said. Then, shortly before he was killed by the police, the suspect uploaded a photograph of the victim to Twitter, he added.
The gruesome killing appeared to be the culmination of a couple of weeks of tension at the school, College du Bois-d’Aulne, in a quiet, middle-class suburb north of Paris. Muslim parents upset over the classroom display of two caricatures published by the satirical magazine Charlie Hebdo had contacted school and police officials, but videos uploaded on social media by one father widened the dispute to an outside audience.
Investigators were still trying to piece together how the suspect spent his days before the attack, Mr. Ricard said. But the suspect did not appear to have any direct ties to the school or to have been previously involved in the dispute.
Born in Moscow, the suspect lived in France with the status of a refugee, Mr. Ricard said, adding that he was not known to antiterrorism officials.
The brutal killing was the second violent episode within weeks to be linked to the caricatures published by Charlie Hebdo, which had led to deadly attacks in Paris in 2015. Last month, as the trial of accomplices in the 2015 attack got underway, the magazine republished the drawings — an act that was seen as a bold statement in the name of freedom of expression by some but as reckless and unnecessary provocation by others.
Last month, a 25-year-old Pakistani immigrant attacked two people outside the former offices of Charlie Hebdo, apparently angered after watching videos showing protests in Pakistan against the republication of the cartoons.
Beyond its brutality, Friday’s killing hit a far bigger nerve in France as President Emmanuel Macron and other top government officials rushed to the scene on Friday evening.
Jean-Michel Blanquer, the minister of national education, said that in Friday’s killing, it was “the republic that was attacked.’’ France said a ceremony would be organized to pay national homage to the slain teacher.
The minister’s words reflected the central role played by France’s public schools — hewing to a national curriculum established by the central government — in instilling civic values and a national identity. But they also underscored the recurring tensions between France’s traditional republican values and those of newer arrivals, especially those of Muslim faith who oppose the publication of the caricatures.
The tensions at College du Bois-d’Aulne emerged early this month as the teacher — who was 47 and, according to parents and students, had taught at the school for only few years — broached the topic of freedom of expression.