A man fatally has stabbed a police administrative worker as she walked into a police station in a Paris commuter town.
President Emmanuel Macron on Friday (local time) said France had again been the victim of a terror attack.
The assailant stabbed the woman twice in the throat security sources said.
Mr Macron identified the victim as Stephanie and said the country stood by her family’s side.
“We will stop at nothing in our resolute fight against Islamist terrorism,” Mr Macron tweeted from his presidential jet as he flew back from Chad.
The attacker was shot dead by police officers.
France’s anti-terror prosecutor said he was leading the investigation because the assailant had previously scouted out the site and because of what he said during the attack.
A judicial source close to the investigation said the attacker had shouted “Allahu akbar” or “God is greatest”.
The attacker was a Tunisian citizen residing in France on legitimate papers, the security officials said.
BFM TV reported that he had lived in France illegally before obtaining a residency card, which was due to expire later this year.
He was not previously known to France’s intelligence agencies, a third security source added.
Prime Minister Jean Castex said France had lost an “everyday heroine” to an act of infinite cowardice.
The police station was located on a leafy residential street in Rambouillet, a middle-class town about 50km southwest of Paris.
The victim had two daughters, said Michel Camboulives, whose partner was a colleague and close friend of the victim.
He said his partner described her as an adorable woman.
“I don’t know how such things happen here,” Mr Camboulives said.
“I mean, we’re in France.”
“My partner’s just in pieces. This was her best friend. She couldn’t speak on the phone… She was saying: ‘It could have been me, or it ought to have been me’.”
Friday’s attack came six months after a Chechen teenager beheaded a school teacher in Conflans, another Paris satellite town.
Mr Macron has expressed increasing concern over radicalisation – often non-violent – within Muslim communities, warning that Islamist separatism is threatening to take control in some areas.
He has called for an “enlightened Islam” in France, saying Islam and radical Islamism must not be conflated.
Marine Le Pen, leader of the far-right and the strongest challenger to Macron’s re-election bid, demanded more protection for police.
“Support the police, expel illegal immigrants, eradicate Islamism,” she tweeted.