Khalid, Logic, and Alessia Cara perform “1-800-273-8255” at the 2017 MTV Video Music Awards. (Matt Sayles/Invision/AP)

At the VMAs on Sunday night, rapper Logic shared the stage with suicide attempt survivors as he offered an emotional performance of his anthem “1-800-273-8255,” named after the suicide prevention hotline.

The song, which features Alessia Cara and Khalid, begins from the perspective of someone calling the number — known as the National Suicide Prevention Lifeline — and confessing that they “don’t want to be alive.”

Ultimately, the song delivers a message of hope — the second verse features the lyrics “You don’t gotta die, I want you to be alive,” told from the perspective of the person offering emotional support at the other end of the line. The song’s final lyrics find the caller determined to keep fighting: “The lane I travel feels alone / but I’m moving ’til my legs give out / and I see my tears melt in the snow / but I don’t wanna cry / I don’t wanna cry anymore / I wanna feel alive / I don’t even wanna die anymore.”

The music video for the song explores these themes through the perspective of a young man struggling with his sexuality.

At the VMAs, Kesha introduced Logic before the performance, saying that the song and its music video moved her to tears. “The truth is piercing and the truth is what matters,” she said. “The truth is none of us are alone.”

“1-800-273-8255,” is featured on “Everybody,” Logic’s third studio album, which debuted at No. 1 on Billboard’s Hot 200 (a first for the rapper) in May and explores a number of serious themes, including racism, politics and Logic’s own biracial identity. Logic explained the origins of “1-800-273-8255” in a video produced by Genius earlier this year.

“I think it was just a record that was, like, years in the making,” the Gaithersburg, Md., native said. “Who really wants to write a song about suicide, you know? But I was like f‑‑‑ it, I’m gonna do it, I’m gonna make this sh‑‑ an anthem.”

Logic isn’t a household name in the way that many of his fellow VMA attendees are. But he has a devoted fan base, and has made a habit of visiting fans at their homes throughout his career. He told Genius that people routinely told him that his music saved their lives.

“In my mind, I was like, ‘Man I wasn’t even trying to save anybody’s life,'” he said. “And then it hit me — the power that I have as an artist with a voice. I wasn’t even trying to save your life. Now what could happen if I actually did?”

Right after the song’s release in April, Logic addressed his intentions in several tweets, writing that “over the years so many of you guys have told me that my music has helped you through so many tough times.”

“I’m beyond humbled, ” he added. “But I felt I haven’t done enough. I felt compelled to make a song that could actually help you.”

Logic’s team coordinated with the National Suicide Prevention Lifeline ahead of the song’s release, and the organization’s director, John Draper, praised “1-800-273-8255” in a statement earlier this year.

“By sharing these stories of recovery from individuals who have been there and have survived their own crises, we can change the conversation about suicide from one of tragedy and isolation to one of hope,” Draper said. “It’s an honor for us to be working alongside Logic to help people in despair find hope and meaning.”

Related: 

MTV VMAs: 13 things to know, from Kendrick Lamar’s many wins to Taylor Swift’s video

‘13 Reasons Why’ depicts a graphic suicide. Experts say there’s a problem with that.

Logic looks to take his career to the final frontier