"I was dancing with the devil / Out of control," Lovato sings on the track. "Almost made it to heaven / It was closer than you know"

Demi Lovato is healing through music.

On Friday, the singer released her powerful track "Dancing with the Devil," where she sings about the relapse, which led to her near-fatal overdose.

"It's just a little red wine, I'll be fine / Not like I wanna do this every night," the 28-year-old starts, referring to her relapse. "I've been good, don't I deserve it? / I think I earned it, feels like it's worth it / In my mind."

By the second verse, it's "a little white line," then "a little glass pipe."

"Tin foil remedy, almost got the best of me," she sings, referring to smoking heroin. "I keep prayin' I don't reach the end of my lifetime."

In the track's chorus, she refers to her overdose directly, singing that she "almost made it to heaven" by "playing with the enemy / gambiling with my soul."

"It's so hard to say no / When you're dancing with the devil," she sings.

RELATED VIDEO: Demi Lovato: It Feels Great to Live In My Truth Fearlessly

The new single, which follows the likes of "Anyone" and "What Other People Say" are set to be a part of her album Dancing with the Devil... the Art of Starting Over. The first three songs on the record, whose tracklist features 19 songs, are thought to delve into her pre-overdose experience as a prelude to her "starting over."

Sharing an acoustic version of the track, Lovato tweeted, "It feels absolutely unreal having this out right now, I love you all so so much," about her new song.

The album is set to feature tracks alongside the likes of Ariana Grande, Noah Cyrus and Saweetie.

If you or someone you know is struggling with addiction, please contact the SAMHSA substance abuse helpline at 1-800-662-HELP.