The star-studded Stand Up To Cancer broadcast raised more than £31 million towards research into new treatments for the disease, Channel 4 said.

Hosted by Davina McCall, Alan Carr, Maya Jama and Adam Hills, the show featured A-list cameos including Ed Sheeran and Olivia Colman.

The broadcast also included a tribute to comedian Sean Lock, who died of cancer earlier this year aged 58.

2013 Fusion Festival – Birmingham
Tom Parker of The Wanted discussed living with a brain tumour during the Stand Up To Cancer broadcast (Joe Giddens/PA)

And The Wanted’s Tom Parker discussed his experience of living with a brain tumour.

The final total raised was £31,169,340, Channel 4 said.

During the programme, Parker shared his advice for other cancer patients.

“I think you have just got to have a positive mindset,” he said. “I think cancer can consume you very quickly and very easily.

“You know, there was a time at the start of this journey where I couldn’t really get out of bed.

Graham Norton Show – London
Ed Sheeran was among the stars who took part in Stand Up To Cancer (Matt Crossick/PA)

“I was just so consumed by cancer and it wasn’t the physical side of things, it was the mental side of things really.

“All I was thinking was I was going to die, what’s the point in getting out of bed.”

Sheeran also played an adapted version of his song Bad Habits which urged viewers to donate to Stand Up To Cancer.

A special edition of Celebrity Gogglebox also featured celebrities including actor Michael Sheen and his girlfriend Anna Lundberg, comedians Aisling Bea and Robert Delaney and Great British Bake Off presenter Matt Lucas and his mother Diana.

Rapper Aitch and England footballer Kalvin Phillips also appeared in the segment.

Former One Direction star Harry Styles also gave viewers a sneak peak into his everyday life as excerpts of him performing household chores were played to viewers.

Sir Tom Jones also delivered a musical tribute to his late wife Linda, who died from cancer.

Ian Katz, chief content officer at Channel 4, said: “It is both heartening and humbling that after such a tough 18 months the British public have shown such extraordinary generosity, and that so many amazing people have done so many amazing things for such a vital cause.

“It’s a sobering fact that one in two of us will get cancer in our lifetime, and all of us at Channel 4 are incredibly proud that this money will go to speed up life-saving cancer research and accelerate new cancer treatments for UK patients.

“We are profoundly grateful to everyone who helped fundraise, contribute to our shows and donate.”