Facebook and Instagram are using AI to spot drug dealers using their sites.

The "proactive detection" technology allows the platforms to remove drug-related images before it has been seen or reported by users.

Social media companies are attempting to stop their platforms being used to sell opioids as the US battles an addiction crisis.

"Our technology is able to detect content that includes images of drugs and depicts the intent to sell with information such as price, phone numbers or usernames for other social media accounts," said Kevin Martin, head of US public policy at Facebook.

He said this freed up human moderators to look at pages, groups and hashtags which may be linked to drug use, as well as looking at trends.

The practice emerged as social media platforms announced a new group, Tech Together to Fight the Opioid Crisis, which also includes Google and Twitter.

The companies are also working with experts at the University of Alabama in Birmingham to monitor new tactics used by dealers, such as street names for drugs.

They will also signpost people who search for drug-related content to US drug and mental health charities.

Speaking at an event organised by US nonprofit the Center for Safe Internet Pharmacies on Tuesday, Susan Molinari, who leads on policy and and government relations at Google, said that 50,000 searches about specific opioid drugs were made each day on the search engine.