The collaboration came about as a result of Kesha working with Macklemore's frequent production partner, Ryan Lewis. The rapper told Rolling Stone
"Ryan had a session with her in Seattle. … They had already done 'Praying
' and they were working on a couple other records that I don't think made her album."
Macklemore continued the story during an interview with Radio.com
"Ryan hit me up like 'Yo, you gotta get in the studio with Kesha, you guys would really click.' She wanted to talk on the phone, and I hate talking on the phone," he joked. "I was like 'oh no, I've gotta talk to this person on the phone, it's gonna be super awkward.' And we got on the phone, and she was hella cool."
"She started sending me voice notes of ideas and sketches, which I really just was like wow, this person is really comfortable with their artistry," he continued. "She was like, 'I'm sick, I have the flu, but here's an idea.' So we got in the studio in Seattle, and she was just great. Vulnerable, open to feedback, and wanted to make the song the best that it could be."