The European Union has approved new copyright rules that will give content rights-holders a greater share of revenue from platforms such as YouTube, Google and Facebook hosting their content.

Representatives of the EU's 28 national governments and lawmakers from the European Parliament reached an agreement on new rules late last month after two and a half years of negotiations and an intense lobbying campaign that pitted tech giants such as Google and Facebook against film and music companies and digital rights campaigners.

The main change to EU copyright rules, if officially approved, would introduce a requirement for platforms such as YouTube to negotiate licences with film producers, record companies, collecting societies and other rights-holders to host content on their sites, while Google News would have to buy licences to host newspaper articles. Small excerpts, or snippets, will be permitted without licensing, however. And hyperlinks are not covered by the rules.

The aim of the copyright directive is to redress what rights-holders call the "value gap" between what platforms earn by hosting others' content and what rights-holders themselves are paid.

The EU's Council of Ministers and the European Parliament still have to formally sign off on the new copyright directive – a move expected to occur later this month.

Julia Reda, a German lawmaker from the digital freedom Pirate Party who is fiercely opposed to the deal, has organised a campaign to block approval of the agreement. But that opposition campaign is not expected to succeed.

Helen Smith, executive chair of independent record companies association Impala, welcomed the agreement. "Impala has been one of the longstanding porters of the legislation," she said. "It's a huge step forward in how platforms deal with rights-holders."

Record companies managed to insert into the final agreement the principle of "appropriate and proportionate remuneration", meaning rights-holders should be paid an amount based on the revenue generated by their material when it is used, rather than a flat fee.

Platforms will also be responsible for content illegally uploaded to their sites.

Critics of the final compromise argued that it would harm freedom of expression on the internet, because vast amounts of content would be blocked by automated filters designed to weed out unlicensed content.

"This deal is a threat to small publishers, authors and internet users alike and risks putting the internet as we know it solely in the hands of the tech and media giants," the opposition's Reda said.

She said the algorithms of upload filters would not be able to tell the difference between copyright infringement and legal parody.

"Even the most sophisticated upload filters routinely block perfectly legal content. Requiring platforms to use upload filters would not just lead to more frequent blocking of legal uploads, it would also make life difficult for smaller platforms that cannot afford filtering software," she said.

Impala's Smith said claims that internet memes would be banned are "completely exaggerated" and that the directive has been carefully drafted to provide for exemptions, such as parody or quotation. "It's one of the most complicated pieces of legislation" the EU has produced, she said.

Mark Jansen, spokesperson for Google in northern Europe, said copyright reform needs to benefit everyone, including European creators and consumers, small publishers and platforms.

"We'll be studying the final text of the EU copyright directive and it will take some time to determine next steps," he said. "The details will matter, so we welcome the chance to continue conversations across Europe."