Mr King went to a Methodist church when he was growing up, but stopped going after he finished high school.
He told Rolling Stone he chose to believe in God "because it makes things better. You have a meditation point, a source of strength".
He continued: " choose to believe that God exists, and therefore I can say, 'God, I can't do this by myself. Help me not to take a drink today. Help me not to take a drug today.' And that works fine for me.
"[I've] gone back and forth about whether or not there's an outside evil, whether or not there's a force in the world that really wants to destroy us, from the inside out, individually and collectively.
"Or whether it all comes from inside and that it's all part of genetics and environment.
"Evil is inside us. The older I get, the less I think there's some sort of outside devilish influence; it comes from people."
Mr King made the comments as he releases his new book, Revival, which is about a Methodist minister who loses his faith.
He is famous for a number of books including The Shining and Misery, which were both made into films.