BRUSSELS, Jan 29 (Reuters) - European Union countries can refuse to disclose names of file sharers on the Internet in civil cases, the EU’s top court said on Tuesday in a blow to copyright holders trying to fight digital piracy.

The European Court of Justice ruled on a dispute between Spanish music rights holders association Promusicae and Spain's top telecoms operator Telefonica TEF.MC.

Telefonica argued that, under a national law based on EU rules, it only had to disclose the name of an Internet subscriber for criminal actions, not civil ones.

“Community law does not require the member states, in order to ensure the effective protection of copyright, to lay down an obligation to disclose personal data in the context of civil proceedings,” the court said in a statement.

Promusicae wanted names of people using Telefonica’s Internet gateway to share copyright material on the Web so it could start civil proceedings against them.

Civil proceedings are cheaper than criminal proceedings which typically require a higher burden of proof.

An adviser to the ECJ said last year that EU provisions safeguarding personal data effectively overrode the rights of intellectual property rights holders.