A pirate internet TV scam may have cost broadcasters more than £40m, according to Police Scotland.

The force is carrying out an investigation, thought to be the largest of its kind in the world, centring on the sale of illegal TV boxes to hundreds of pubs and clubs.

Officers raided two premises in Glasgow on Thursday as part of the inquiry.

The scam involves setting up TV boxes in venues to illegally stream TV, sport and films from legitimate broadcast networks.

Investigators from the Federation Against Copyright Theft (Fact) have been working with Police Scotland on the investigation for the past 16 months.

The inquiry has also been receiving assistance from the English Premier League, while officials from Sky and BT were in Glasgow to watch the raids.

A police spokesman said anyone found offering access to pirated streams of live football could face a lengthy prison sentence.

In 2015, two men who admitted supplying cards to hundreds of pubs and betting shops were jailed for three and a half years.

The spokesman said: "As of today we estimated about 500 pubs might be involved, but today's investigation has suggested it could be thousands.

"This is undoubtedly the biggest operation of its kind in the world in terms of recovery. It's a process that's been done elsewhere but not on this scale, this is the biggest."

Fact was taking steps to take down a server allegedly involved in the operation. It argues it is not a victimless crime and police suggest it could mean higher subscription rates for honest businesses and customers.

Kieron Sharp, Fact's director general, said: "Pub landlords, as well as the general public, need to be aware that IPTV and set-top boxes with apps and add-ons allowing the streaming of pirated TV, sports and films are very much illegal.

"Content theft deprives businesses and individuals of an honest livelihood and so on behalf of our members,

"Fact will continue to work with police forces across the UK to crack down on the illegal sale of these boxes."

Alison Dolan, deputy managing director of Sky Business, said: "We work hard to protect the investment of our customers and we therefore support action to stop illegal suppliers who threaten their businesses."