The song's title was inspired by a comment made by Oak Felder's wife to him just before his songwriting session with Lovato. He recalled to Songwriter Universe
"Early that morning, I was on the phone with my wife. I live in Atlanta [with her] but I work in Los Angeles. I'm in Atlanta for two weeks at a time and then I'm in L.A. for two weeks. We were in the process of buying a house, and you know, that can be a little stressful. So my wife and I were having tense words on the phone. I wouldn't say it was an argument, but it wasn't a great conversation (laughs). And she said something that ticked me off. She said 'You know what, it would be a lot easier to figure this out if we weren't talking on the phone.' And I'm saying, 'Come on baby, I'm working, you can't be mad at me for working…I really don't appreciate that statement…I think you should apologize.' And she said, 'I am not apologetic about that at all. I'm sorry that you feel that way but I'm not sorry' (laughs). Then I said, 'What did you just say?' She said, 'I'm sorry but I'm not sorry.' And I was like, 'Yes! Thank you for that!' Then I said, 'Let me call you back.'
I wrote down that concept in my phone, and when we met that day with Demi Lovato, I blurted it out: "Why don't we write a song called 'Sorry Not Sorry'." And she connected to it. It connected specifically for her, because there's a lot of things in her past that people are looking for her to be apologetic for. And there's a lot of improvement that she's done to herself, to being a confident, beautiful woman. And she's not apologetic about working on herself and getting her stuff together. So I think the concept connected to her instantaneously. And when we started writing, Demi was instrumental in creating the structure—she was 100% the force behind writing a lot of the ideas of the record. And then of course Sean Douglas, a good friend of mine and a great songwriter, offered to help us knock it out, and that's how that song came together."