France runs a vast electronic surveillance operation, intercepting and stocking data from citizens' phone and internet activity, using similar methods to the US National Security Agency's Prism programme exposed by Edward Snowden, Le Monde has reported.

An investigation by the French daily found that the DGSE, France's external intelligence agency, had spied on the French public's phone calls, emails and internet activity. The agency intercepted signals from computers and phones in France as well as between France and other countries, looking not so much at content but to create a map of "who is talking to whom", the paper said.

Le Monde said data from emails, text messages, phone records, accessing of Facebook and Twitter, and internet activity going through sites such as Google, Microsoft or Yahoo! was stocked for years on vast servers on three different floors in the basement of the DGSE headquarters.

The paper described the vast spying programme as secret, "outside any serious control" and illegal.

The metadata from phone and internet use was stocked in a "gigantic database" which could be consulted by six French intelligence and security agencies as well as the police.

The paper said Bernard Barbier, technical director of the DGSE, had previously described the system as "probably the biggest information centre in Europe after the English".

Referring to the system as a "French Big Brother", Le Monde said the French state was able to use the surveillance "to spy on anybody at any time". The paper wrote: "All of our communications are spied on."

Le Monde said that after Snowden's revelations about the NSA's Prism surveillance programme prompted indignation in Europe, France "only weakly protested, for two excellent reasons: Paris already knew about it, and it was doing the same thing".

When revelations about the Prism programme harvesting citizens' data emerged, the French government did not immediately comment. But after fresh allegations about the US spying on the European Union and foreign embassies, including the French embassy in Washington, the president, François Hollande, said these practices must "cease immediately". France demanded the suspension of talks on the EU-US free trade pact until it had received full explanations about surveillance.

The foreign minister, Laurent Fabius, said this week that France did not spy on the US embassy in Paris because "between partner countries" these "were not the sorts of things that should happen". Asked about the US spying, Fleur Pellerin, the junior minister for the digital economy, told BFMTV this week that she found the "generalised surveillance of citizens" was "particularly shocking".

The Guardian revealed last month that Britain's spy agency GCHQ had secretly gained access to the network of cables which carry the world's phone calls and internet traffic and had started to process vast streams of sensitive personal information which it was sharing with its American partner, the NSA.