Democratic presidential candidate Pete Buttigieg on Thursday night said God wasn't going to "let us off the hook" if we don't do something to combat climate change.

The South Bend, Ind., mayor appeared on The Late Show with Stephen Colbert, where he was asked about his appearance in CNN's climate town hall the night before. Colbert referenced Buttigieg's comment during the town hall when he said ignoring climate change was a "kind of sin."

"In what way is climate change a transgression of God's laws?" Colbert asked.

Buttigieg said he wasn't out to impose his religious views on others, but he cited his Episcopalian faith to explain how the environment and stewardship are key principles he believes in.

"To me, environmental stewardship isn't just about taking care of the planet. It's taking care of our neighbor," Buttigieg said. "We're supposed to love our neighbor as ourselves, and the biggest problem with climate change isn't just it's going to hurt the planet in some shape or form. The planet is still going to be here. It's that we are hurting people."

"The way I see it, I don't imagine that God's going to let us off the hook for abusing future generations anymore than you'd be off the hook for harming somebody right next to you. With climate change, we're doing both," Buttigieg continued.

During Wednesday night's town hall, Buttigieg invoked religion to discuss climate change, saying, "Let's talk in language that is understood across the heartland about faith."

"If you believe that God is watching as poison is being belched into the air of creation, and people are being harmed by it—countries are at risk of vanishing in low-lying areas—what do you suppose God thinks of that? I bet He thinks it's messed up," Buttigieg said.

"You don't have to be religious to see the moral dimensions of this because frankly, every religious and nonreligious tradition tell us that we have some responsibility of stewardship, some responsibility of taking care of what's around us—not to mention taking care of our neighbor," he added. "At least one way of talking about this is that it's a kind of sin."

He also compared climate change to the Great Depression and World War II.