The European Court of Justice has ruled that content owners cannot ask ISPs to filter out illegal content.
The ruling could have implications for the creative industries as they attempt to crack down on piracy.
The court said that while content providers can ask ISPs to block specific sites, wider filtering was in breach of the E-Commerce Directive.
A Belgian court had previously ruled that a local rights holder could force an ISP to filter content.
The case stems back to 2004 when SABAM, a Belgian company responsible for authorising music rights, discovered that customers of local ISP Scarlet were downloading music illegally via peer-to-peer networks.
The Brussels Court of First Instance ordered Scarlet to make it impossible for its customers to send or receive files containing music from SABAM's catalogue on such networks.
Scarlet appealed to the Brussels Court of Appeal, claiming that the injunction failed to comply with EU law.
It said that the obligation to monitor communications on its network was in breach of the E-Commerce Directive.
Seven years on, the European Court of Justice agreed.
It said that the move could affect Scarlet's ability to do business because it would have to "install a complicated, costly, permanent computer system at its own expense".
The court ruled that the filtering could infringe the rights of customers and their right to protect their own data.
It could also mean that legal content was blocked.
"Such an injunction could potentially undermine freedom of information since that system might not distinguish adequately between unlawful content and lawful content with the result that its introduction could lead to the blocking of lawful communications," the court said in a statement.
TalkTalk and BT are currently embroiled in legal action against the UK's Digital Economy Act. They claim the law - which lays out rules for combating piracy - is also in breach of the E-Commerce Directive.
While the European ruling has "some relevance" to its case, it is not directly linked, said Andrew Heaney, TalkTalks' head of regulatory affairs.
"The idea of filtering was talked about in the UK but it came off the table some time ago. This judgement is effectively about an old issue," he said.
Internet freedom organisations welcomed the news.
Peter Bradwell of the Open Rights Group said: "This judgement is a victory for freedom of expression online. It draws a thick line in the sand that future copyright enforcement measures in the UK cannot cross.
"Invasive and general surveillance of users is unacceptable. This helps to nail down the limits of powers to curtail people's freedom to communicate online."