Media playback is unsupported on your device Media caption Miller (pictured) was due to go on tour next month. His friend, rapper Pittsburgh Slim, was among those paying tribute

Musicians have been expressing their sadness and paying tribute to US rapper Mac Miller, who was found dead at his California home on Friday aged 26.

"It's so heartbreaking," singer Ed Sheeran wrote on Instagram, describing the rapper as "such a sweetheart".

Snoop Dogg, Chance the Rapper and Missy Elliott have also shared messages.

Miller, whose real name was Malcolm James McCormick, was often open about his substance abuse and reportedly died from a suspected overdose.

"I'm so saddened to hear about Mac Miller, such a kind spirit," wrote fellow rapper Missy Elliott, adding that she was sending "prayers for strength" to his family.

In a moving tweet, Chance the Rapper said he was "completely broken" after hearing the news and described Miller as "one of the sweetest guys I ever knew".

The legendary West Coast rapper Snoop Dogg said that Pittsburgh, the city in Pennsylvania where Miller was born, had "lost a real one".

"Words can't express how much I loved Mac," said the guitarist and producer Thundercat, adding: "If I could have been with him all the time I would have, happy for the time we spent together. I will always celebrate his life."

Others in the industry to pay tribute include the singer and producer Pharrell Williams, the rapper Wiz Khalifa, singer Solange Knowles and singer-songwriter Khalid, who said the news "hurts my heart".

Miller rose to fame after topping US charts with his debut album in 2011. He released his latest record, Swimming, earlier this year and was due to go on tour.

The rapper went through a well-publicised break-up with singer and girlfriend Ariana Grande earlier this year.

The pair, who met in 2012, collaborated on a number of songs and performed together at the One Love Manchester concert in 2017.

Charges were filed against Miller last month after he was arrested in May for driving under the influence and hit and run.

Grande spoke out publicly about ending their "toxic relationship" after fans blamed her for his arrest.

Image copyright Getty Images Image caption Grande suspended comments on her Instagram account on Friday shortly after Miller's death

"I am not a babysitter or a mother and no woman should feel that they need to be," she said in a typed message posted on social media.

Grande said she had "tried to support his sobriety" for years, and was praying that he "figures it all out".

An early beginning

Born in Pittsburgh, Pennsylvania, Miller began to focus on his music while still at school and released his first mixtape under the name EZ Mac at just 15.

Maturing in the public eye, he starred in a MTV reality series in 2013 which followed him and a group of friends after he moved to Los Angeles to pursue his career.

He released a series of albums and EPs across the last decade, collaborating with high-profile artists like Pharrell Williams and Kendrick Lamar.

In his final tweets posted on Thursday, the rapper promoted the North American tour he was set to embark on next month.

He was "a bright light in this world for his family, friends and fans." his family said, in a statement confirming his death.

'Mac Miller could do it all'

Analysis by BBC Music Reporter Mark Savage

A lot of rappers don't make beats. A lot of beat-makers can't rap. Mac Miller could do it all, lending an uncommon intimacy to his best songs.

He started piano lessons at the age of six, later picking up drums, bass and keyboards. By the age of 15, he'd released his first mixtape, But My Mackin' Ain't Easy, but it was his fourth release, 2010's KIDS, a playful, freewheeling collection of party tunes, that won him a recording contract.

Over the years, he shed his frivolous, frat-boy reputation, making increasingly mature, introspective records that dealt with his personal demons; as well as 2016's The Divine Feminine, a naive but affecting (and occasionally too-graphic) concept album about what he called "the feminine energy of the planet," but which many took to be a tribute to his partner, Ariana Grande.

Image copyright Getty Images Image caption The rapper had more than eight million followers on Twitter

In music, and in his interviews, he was open about his addictions - which eventually prompted Grande to end their relationship, describing it as a "toxic relationship". But Miller refused to exploit their break-up on his latest album, Swimming. "Everybody wants a headline / I don't got nothin' to say," he rapped on Programs, released in May, just weeks after their split was confirmed.

Instead, the album documented his ongoing struggles with substance abuse. "Got my head underwater, but I ain't in the shower, and I ain't getting baptised," he confessed on Jet Fuel. The halting vocals and fractured, subdued production made it clear he was suffering but there was always a sense of optimism - a promise that those demons could be beaten.

Tragically, it appears he lost the battle.

Follow us on Facebook, on Twitter @BBCNewsEnts, or on Instagram at bbcnewsents. If you have a story suggestion email entertainment.news@bbc.co.uk.