PARIS — A veteran police employee in France slipped a knife through security at the heavily guarded Police Headquarters in the heart of Paris on Thursday, killing four of his colleagues before being shot dead in the building’s vast courtyard.
The employee, a 45-year-old man who worked in computer services for the intelligence division of the Paris police, moved methodically from his office, up the stairs and back down, killing one woman and three men as he went, police union officials told French television.
The attack immediately raised fears of a return to the waves of terrorism that hit Paris in 2015 and 2016, which included assaults on the police, although officials were looking elsewhere for a motive, at least for now.
Discontent among police officers was already rising before the attack, and the authorities will almost certainly be asked to explain how a man with a knife was able to enter a heavily secured Police Headquarters filled with armed officers and kill four people before finally being brought down.
The unhappiness and disquiet plaguing the French police have led to a record number of suicides and to a mass demonstration by officers through Paris on Wednesday, the biggest in nearly 20 years.
“It might be the expression of a new malaise at the heart of the police, like this wave of suicides,” Denis Jacob, a police union official, told French television on Thursday after the attack. An official with another police union said there were morale problems among administrative workers, who were held in low esteem.
The attacker had converted to Islam, according to a police spokesman, who spoke on the condition of anonymity in accordance with police protocols. The spokesman added that that was just one element of the investigation, and that his conversion “doesn’t mean that he is radicalized.”
Mindful of the deep unease among the police, signaled by the march, the country’s top leadership — President Emmanuel Macron, along with his prime minister and interior minister — quickly rushed to Police Headquarters, a massive 19th-century building on the Île de la Cité, adjacent to Notre-Dame cathedral.
Mr. Macron, speaking later on Thursday from southern France, where he was debating his government’s pension reforms, called the killings a tragedy and observed a minute of silence with the 500 or so people who had gathered for the discussion.
The attacks began shortly before 1 p.m. Paris time, when the headquarters was bustling with activity: document seekers getting papers signed, police officials piling out of their offices to go to lunch and all around a swirling crowd of visitors who fill the island in the middle of the Seine river.
The building houses not only the offices of the police, but also numerous other agencies, including those regulating the presence of foreigners in Paris. It is where Americans living in Paris, for instance, apply for residency permits.
The suspect, a 20-year-veteran of the force, was not immediately identified by the police. He struck in his own office first before going upstairs to kill two more colleagues, Mr. Jacob, the union official, said. By then, the alarm had been raised. As the attacker entered the sprawling courtyard, traversed by thousands of visitors every day, a police officer took out his weapon and shot him, officials said.
The suspect had not previously exhibited signs of trouble, officials said.
“He set himself on a murderous path,” the interior minister, Christophe Castaner, told reporters at the site. “There had never been problems with his behavior.” Prosecutors said his home was being searched.
The sound of gunshots was the first warning many in the building had of the attack, and it brought employees rushing out of their offices. The police quickly locked down the island, barring all visitors.
Youssouf Dramé, a human resources employee who worked in the building, was having lunch at his desk when he heard noises in the courtyard. “I heard shouting: ‘Drop your weapons! Drop your weapons!’” Mr. Dramé said. He then heard two shots. Two colleagues in the office began to cry.
Employees said they were blocked in their offices and could not get out because the area was cordoned off as officers looked for a potential second assailant. They were able to evacuate a few hours later.
“Everything happened very quickly,” said Mr. Dramé. “It seems almost hallucinatory, but at the same time, given everything that’s going on with the cops at this point, it’s unfortunately not that surprising.”
“Still,” he added, “we’re in deep shock.”
It was not immediately clear how the attacker had passed through the metal detectors with his knife. French news outlets suggested that he had evaded detection by carrying a “ceramic knife,” a theory that the authorities had not confirmed by midafternoon.
“We don’t know his motivations,” Loïc Travers, another police union official, told reporters near the Police Headquarters on Thursday. “It’s obviously someone who blew his top.”
Pauline Rossignol, a 28-year-old human resource officer at the police prefecture, was on her lunch break when the attack occurred. She said she had experienced enough “tragedies” affecting her colleagues.
“It’s going to be one more minute of silence, after so many,” Ms. Rossignol said as she sat sobbing on the stairs by the banks of the Seine, unable to go back to her office.
“There have been too many suicides of police officers, too many of them who died in terrorist attacks,” she added. “Police forces suffer a lot; we are a target.”
The assault is likely to rekindle security concerns in the French capital after several attacks in and around Paris, most notably two large-scale assaults in 2015: Terrorists attacked the satirical newspaper Charlie Hebdo, killing 12 people including a police officer, and then carried out a coordinated, nighttime rampage across the city that left more than 100 dead.
In 2016, an Islamic State assailant fatally stabbed a police officer and his companion at their home in a town about 35 miles west of Paris, while their child was present. In 2017, a veteran police officer, Xavier Jugelé, was shot and killed by a gunman on the Champs-Élysées.
Indeed, at Wednesday’s march, officer after officer talked about a crisis of morale in the 150,000-strong national police force after a year of putting down Yellow Vest protests, public criticism over the severity of police tactics, budget cuts and a feeling of government neglect.
There were ghoulish commemorations of the officers who have killed themselves this year — more than 50, well on the way to a record — including a mannequin hanged in effigy, and 51 cardboard coffins.
Police officers from all over France and every branch of service, including forensics and riot officers on the front lines against the Yellow Vests, demanded better working conditions, more money and more respect from the public.