Spain is preparing legislation that would impose a 5.0-percent tax on steaming giants like Netflix with the funds used to boost Spanish cinematic production, the government said on Friday.

The draft law, which would tax online entertainment platforms on the basis of earnings generated in Spain, seeks to bring existing legislation "in line with the reality of the market where new audiovisual players have multiplied as a result of new technologies", an economy ministry statement said.

The reform is part of the government's Digital Spain 2025 strategy, one of whose aims is to improve the country's appeal as one of the most attractive locations for shooting films and series.

The text "extends the obligation to fund European audiovisual production to those providers offering services in Spain even if they're not based there" in a nod to platforms like Netflix, HBO, Disney and Amazon Prime Video.

"Providers with a turnover of more than 50 million euros generated from services in Spain must allocate 5.0 percent of these revenues to finance European audiovisual works or as a contribution to the Cinematography Protection Fund," it says.

Of that amount, 70 percent must be used to finance audiovisual works by independent producers, and a minimum of 40 percent must be used to fund independent films "in any of Spain's official languages".

For those earning under 50 million euros, that 5.0 percent can be diverted into buying the rights to finished European productions, but at least 70 percent must go towards works by independent producers.

Those earning under 10 million euros in Spain will be exempt from the proposed tax.

Global giants such as Amazon, Google and Netflix often pay very little tax in nations where they are not physically present, presenting a major challenge for many countries.

Early last month, the Spanish government gave final approval to a 3.0 percent tax on revenues generated by digital giants such as Google, Apple, Facebook and Amazon which will come into effect within three months.

It will apply to all internet giants with annual global sales of over 750 million euros and 3.0 million euros in Spain.