Wednesday is the last day of France's state of emergency, imposed after terrorist attacks on November 13, 2015 in which 130 people were killed.
The state of emergency is due to lapse automatically on November 1 at the end of its sixth extension, voted by parliament in July.
Instead a number of more restricted security measures, signed into law on Monday by President Emmanuel Macron, will come into force.
"A promise kept: we are ending the state of emergency on November 1 while reinforcing the security of our fellow citizens," Macron wrote on Twitter.
Nobody doubts that, as Interior Minister Gerard Collomb said after Macron signed the law, "The terrorist threat remains great."
The Daesh terrorist group, at the height of its power in 2014 and 2015 when it controlled swathes of Syria and Iraq, frequently singled France out as a target for overseas attacks.
The group is now seriously weakened, having lost its twin capitals of Mosul and Raqqa to Iraqi security forces and U.S.-backed Syrian Democratic Forces (SDF) respectively, while battling with the Assad regime in their final eastern Syrian holdouts.
But French authorities warn that the threat of attacks inspired by its rhetoric and online propaganda remains high. A total of 230 people were killed in the attacks conducted in the country since the attacks in Paris on Nov. 2015. Dozens more have been killed in similar attacks elsewhere in Europe, primarily in Britain and Belgium.
Speaking to the European Court of Human Rights in Strasbourg, eastern France, Macron said Wednesday that "jihadist terrorism" remained the biggest security threat to France.
"Terrorism targets European society and values just as it targets government and state. We are being attacked because of what we stand for," said Macron, who took office in May.
This is the first time a French president made an address before the 47-member ECHR panel.
"The democratic debate took place, civil society expressed itself and the text was voted [through] by a very large majority... It is an effective, respectful and protective law and is part of the European Convention on Human Rights," Macron said, explaining the outcome of the law would be evaluated in two years.
The government says the state of emergency has helped intelligence agencies to thwart more than 30 attacks. Many of those emergency powers will now be enshrined in law.
"We're fighting terrorism with determination and we will continue to do so within the bounds of the law and with the oversight of judges," Macron said.
In his speech, the pro-European leader also defended the 58-year-old European court, whose rulings have been strongly criticized by some of its 47 member states like Britain, Russia and Turkey.
Controversy surrounds the new anti-terrorism law
The right-wing opposition has criticized Macron for ending the state of emergency when there is a continuing threat. But for others, the new law that replaces the state of emergency is itself a threat to rights.
Amnesty International has called for the state of emergency to be lifted for almost two years, according to its French spokesperson on liberties Dominique Curis.
"In the end, in fact, it has not been completely lifted," she argues.
The new law adopts a logic of giving more powers to the executive, she says, "all on a very vague basis that leaves a lot of room for interpretation."
"France has become so addicted to the state of emergency that it is now injecting several of these abusive measures into ordinary law," Human Rights Watch said before parliament backed the legislation.
The new law has also been criticized by France's rights ombudsman Jacques Toubon, who says that allowing the freedom of individuals to be restricted on the basis of suspicions or attitudes is an attack on the fundamental principles of criminal law.
U.N. human rights experts Fionnuala Ni Aolain and Michel Frost warned last month of "vague wording" in the draft law and "grave consequences for the integrity of human rights." They also warned that France's Muslim population could be discriminated against and disproportionally targeted by the new powers.
The Senate amended the initial government draft to ensure that those powers will expire automatically at the end of 2020.
Here is an overview of the main provisions of the new law:
1. Movement Restrictions: Under the new law, persons with links to terrorist organizations can be forbidden from leaving their town or city of residence and required to report daily to police. They can also be banned from specified places. The measures can only be taken to prevent acts of terrorism. The emergency law was stricter, allowing partial house arrest. Its provisions were used not just against suspected terrorists, but also to ban suspected radical leftists from demonstrations.
2. House Searches: Under the new law, authorities can still carry out searches of homes, but only to prevent acts of terrorism. In contrast to full emergency powers, searches must be approved by a judge.
3. Closing Places of Worship: Under the new law, the authorities retain the power to close places of worship where extremist ideas are propagated. That can include promoting hatred or discrimination, as well as inciting violence or supporting acts of terrorism.
4. Identity Checks around Ports and Airports: The new law provides that security forces can check the identity of persons within a 10-kilometer radius of ports and international airports in order to prevent cross-border crime. The government had initially proposed a 20-kilometer radius. Newspaper Le Monde calculated that that would have covered 67 per cent of the French population, including 36 of the country's largest 39 cities. Unlike the other powers, this one will not expire automatically in 2020.
5. Security Perimeters around Events: The new law continues emergency powers under which security forces and security guards can search property and frisk persons at and near major public events that could be targeted by terrorists.
Nearly 240 lives lost in attacks since 2015
Below is a chronology of deadly attacks that have hit the country since early 2015, claiming more than 230 lives:
October 1, 2017: Two young women are killed in a knife attack at the main railway station in Marseilles, southern France. Eyewitnesses say the killer shouted "God is great" in Arabic. He is shot dead by police.
June 19, 2017: A man rams the lead van in a police convoy on the Champs-Elysees Avenue in central Paris with a car filled with ammunition and gas canisters, but kills only himself.
April 20, 2017: A gunman shoots a policeman dead on the Champs-Elysees. He also injures two officers and a German tourist before being shot dead by police.
March 18, 2017: Troops shoot a man dead in Paris Orly airport after he tries to seize a patrolling soldier's gun.
July 26, 2016: Two assailants, claiming to be members of the Daesh terrorist group, kill an 84-year-old priest in a church in northern France and are killed by police as they leave the church.
July 14, 2016: 84 people are killed and many are wounded when an attacker drives a truck into a crowd of Bastille Day revelers in Nice.
June 14, 2016: A police commander and his female companion are killed in their home by a man who then posts a live Facebook video pledging allegiance to Daesh.
November 13, 2015: Daesh terrorists kill 130 people in Paris in coordinated attacks at the Bataclan concert hall and nearby bars and restaurants. In addition, three terrorists blow themselves up outside the Stade de France during a football friendly between France and Germany but without killing anyone else.
June 26, 2015: One person is beheaded and two injured in a terrorist on the fortified plant of U.S. chemical company Air Products in Saint-Quentin-Fallavier. Authorities say the main suspect had ties to Salafist organizations.
January 7-9, 2015: Twelve people are killed at the offices of French satirical magazine Charlie Hebdo. The gunmen, brothers Said and Cherif Kouachi, die in a shootout with police at a hideout north-east of Paris. A police officer and four hostages at a supermarket are killed by another terrorist, Amedy Coulibaly, who is fatally shot by security forces.