The Comic Relief fundraiser has raised £30m in a night of comedy and entertainment that saw an array of stars take part in sketches, live performances and fundraising challenges.

The total amount was announced by host Davina McCall at the close of the three-hour Red Nose Day programme on Friday. Highlights included a spoof of The Traitors starring Anna Friel as Claudia Winkleman and a bank heist sketch with Luther star Idris Elba.

The broadcast followed BBC Radio 1 presenter Greg James completing a 630-mile tandem cycling challenge, raising £4m for charity.

The funds will support projects that provide access to food and shelter for people facing hardship in the UK and around the world.

McCall was joined throughout the evening for the BBC One broadcast by a host of co-presenters from the comedy world including Katherine Ryan, Nick Mohammed, Joel Dommett and Catherine Tate.

Tate appeared as her character Nan from The Catherine Tate Show, kicking off the broadcast with a rendition of Don't Stop Me Now by Queen alongside an assemble of dancers dressed as grandmas.

Julia Roberts, Daniel Craig and Sir Ian McKellen were among the cameos in a video responding to Nan's letter of invitation to appear on the show. Pop star Olivia Dean also featured and quipped: "Sorry, you're not the nan I need", in reference to her chart-topping hit Man I Need.

Recent Traitors contestants Rachel Duffy and Faraaz Nazoor appeared alongside a string of celebrities in a parody of the hit reality series titled The Traitors: The Movie - The Sequel.

Iain Stirling returned to play this year's joint winner Stephen Libby, alongside other celebrities such as Scott Mills and Alison Steadman, who came face-to-face with the real contestants they portray.

The parody also saw TV personality Vicky Pattison play joint winner Rachel, while DJ Scott Mills appeared as James.

The sketch revisited some of the best moments from series four, with comic and presenter Ruby Wax apparently in the director's chair (although director and producer Ed Bye - who is also married to Wax - was really steering the ship).

Earlier on Friday, BBC Radio 1 presenter Greg James completed a 630-mile tandem cycling fundraising challenge, in which he raised more than £4.2m.

The DJ began the journey in Weymouth, Dorset, last Friday and has since cycled through England, Wales and Scotland, finishing in Edinburgh's Murrayfield Stadium.

Along the way, the second saddle on his two-seater was filled by special guests including comedian Joe Lycett, fellow Radio 1 host Jamie Laing and, in a surprise appearance, the Prince of Wales.

Becoming emotional as he ended the final leg of his ride, James told Radio 1's Jack Saunders it had been an "amazing" experience.

"It's been such a struggle at times but everyone has got me through it," he said.

"The thing I'll remember the most is seeing the joy from everyone and pushing through the pain to get to that joy."

Elsewhere in the show on Friday evening, Elba appeared in The Bank Job alongside ITV This Morning presenters Alison Hammond and Dermot O'Leary, joined by a cast including Chris McCausland, Stephen Mulhern and Natalie Cassidy as they attempted a heist to raise money for Comic Relief.

The Motherland spin-off Amandaland was reimagined in Amandas-land, with the titular character Lucy Punch and her friend Philippa Dunne encountering a series of famous Amandas during a chaotic visit to BBC Broadcasting House.

A comedy of errors ensued as the pair encountered numerous other Amandas including Amanda Holden, Amanda Lamb and Amanda Barrie.

Music performances came from Calum Scott, who sang his hit version of Robyn's Dancing on My Own, while Blessing Offor performed his song, Somebody's Child.

In other skits, Romesh Ranganathan hosted a Weakest Link special, while Ryan appeared in Withering Heights, a parody of Emerald Fennell's recently released Wuthering Heights film adaptation.

The Comic Relief charity was co-founded by comedian Sir Lenny Henry and Love Actually screenwriter Richard Curtis in 1985.

The very first Red Nose Day was in 1988 and raised £15m, with more than 30 million people tuning in.

There have been 21 telethons since then (sometimes it runs every two years rather than annually).

Comic Relief funds programmes both in the UK and around the world that tackle poverty and social injustice. It also supports those facing immediate hardship.

More than £1.6bn has been raised since the charity began.

Matt Bailey completes a marathon in a pedalo two years after completing half that distance.

The BBC Hereford & Worcester team are pushing a giant red nose 26km across the two counties.

The Radio 1 host cycled 1,000km (630 miles) on a tandem bike over the course of eight days.

The cafe, which gives out hot meals and clothes to those in need, has been rewarded by Comic Relief.

The Hope Centre sees about 150 people a week use its supermarket service, a volunteer says.