France's top constitutional court on Wednesday seriously weakened a law backed by President Nicolas Sarkozy that was aimed at punishing Internet pirates.

Sarkozy's ruling majority last month approved legislation that set up an authority to track illegal Internet downloading, giving it the power to cut off web access for repeat offenders.

But the constitutional court ruled that this body should be allowed only to issue warnings and that any decision to cut access must be made only by a judge.

Low priority Internet cases are likely to languish in France's overburdened legal system and the government said it regretted the court's decision.

The court said several parts of the new law were unconstitutional. These powers could restrain ... people's right to express themselves and to communicate freely, it said in a statement.

Sarkozy championed the law which embarrassed the opposition Socialists who antagonized many of their traditional supporters in the arts world by fighting the move.

The decision was very clear. The heart of the government's bill...has been canceled. That means that the Internet is a right, said Jean-Marc Ayrault, president of the Socialists in the lower house of parliament.

Sarkozy's wife, model-turned-singer Carla Bruni, is believed to have pushed the legislation, which was aimed at protecting the revenues of record and film companies and recording artists.

Under the terms of the bill pirates would have had to continue paying their Internet provider while they were cut off.

Opponents have criticized this double punishment and say access to the Internet should be a fundamental right.

Consumer groups also feared intrusive monitoring of online activities and warned that innocent users may be unfairly punished if hackers use their accounts to download files.

However, the music industry, which wants governments and Internet providers to crack down on illegal downloading of copyrighted work, had cheered France's efforts.

Record companies and consumer groups have long been at loggerheads over Internet piracy and the rights of users.

(Reporting by Emile Picy; Writing by Anna Willard; editing by Richard Balmforth)