France’s parliament has approved a bill aimed at fighting hate online that obliges platforms and search engines to remove prohibited content within 24 hours starting July 1.

Lawmakers adopted the proposed legislation on Wednesday. Submitted by French President Emmanuel Macron’s LREM party, the law allows for fines of up to 1.25 million euros ($1.1 million.)

It targets texts, pictures, videos and web pages that incite hatred or violence, or that carry insults of a racist or religious nature.

The bill faced vociferous opposition in France and beyond from critics who said it would curtail the democratic right to freedom of expression.

The Computer & Communications Industry Association, an advocacy group with offices in Washington and Brussels, said it was concerned the French legislation “could lead to excessive takedowns of content as companies, especially startups, would err on the side of caution.”