Johnny Depp has appeared to joke about assassinating US President Donald Trump during an appearance at the Glastonbury Festival.

The actor, who was introducing a showing of his 2004 film The Libertine, began talking about Trump and then asked the audience: "When was the last time an actor assassinated a president?"

He continued: "I want to qualify, I am not an actor. I lie for a living. However, it has been a while and maybe it's time."

The Pirates of the Caribbean star was speaking at Cineramageddon, the festival's drive-in cinema.

His comments come just weeks after comedian Kathy Griffin issued a public apology for appearing in photographs where she was holding a mocked-up severed head that appeared to resemble the US president's.

At Glastonbury, Depp eared a rock star welcome, arriving in a blue vintage Cadillac and jumping up on the bonnet to pose for photographs.

It was while he was taking questions from the 1,500-strong audience, alongside The Libertine's director, Julien Temple, that he made his comments about Trump.

"I think he needs help and there are a lot of wonderful dark, dark places he could go," Depp said, to cheers from the crowd.

"It is just a question - I'm not insinuating anything.

"By the way, this is going to be in the press. It will be horrible [but] I like that you are all a part of it."