Energy Secretary Rick Perry believes that President Trump was chosen by God to lead the country — and he handed the president a one-page description of morally flawed biblical kings as inspiration, he said.

“God’s used imperfect people all through history. King David wasn’t perfect. Saul wasn’t perfect. Solomon wasn’t perfect,” Perry said in an interview on Fox News.

Trump caused a stir in August when he described himself in seemingly messianic terms: In one day, he looked to the sky while calling himself “the chosen one” to handle trade policy, and quoted the words of a conspiracy-theorist radio host who likened Trump to “the King of Israel” and “the second coming of God.”

Perry says he told the president that this posturing, which some critics took as egotistical or even blasphemous, was correct.

“ ‘Mr. President … you said you were the chosen one,' ” Perry recalled saying in the Oval Office. “I said, ‘You were. … You are here in this time because God ordained you.’ ”

Perry noted that he believes Barack Obama was also ordained by God for the presidency.

It’s a common view among some evangelical Christians. Some of Trump’s loudest evangelical defenders, like Franklin Graham, often compare him to sinful but important biblical kings, especially King David — who wrote psalms and slew Goliath but also impregnated Bathsheba and then calculated to have her husband killed.

It’s a less common theme among political figures, before Perry’s comments on Fox News.

Perry, whose trip to Ukraine for the inauguration of Ukrainian President Volodymyr Zelensky is under scrutiny as the House impeachment inquiry probes the Trump administration’s dealings with Ukraine, went on to say that he believes Trump will not be removed from office. (“Oh, Lord, no. Not even close,” he said, when Fox’s Ed Henry asked him about the possibility that Republican senators might eventually vote to impeach the president.)

“He will muscle right on through this. He is an extraordinary individual,” Perry said. "We’ve got a mission here, and we’re going to get through it.”

Perry has served as energy secretary since the beginning of the Trump administration and is soon to leave his post. He led a prayer last week at his final Cabinet meeting.

Perry’s embrace of the evangelical belief that Trump was divinely selected for the presidency gives the viewpoint a more prominent mouthpiece, said John Fea, a Messiah College professor who has written a book about evangelicals’ embrace of Trump. “A lot of times, when you see this language through American history -- it’s largely from the fringe,” he said. “Now you have it as a talking point within a major political party. You have it coming from the mainstream. It’s not just fundamentalist clergy -- it’s now the secretary of energy.”

Suggesting that Trump was picked by God implies that those who oppose him are opposed to God’s will, Fea noted. “If Obama was God’s anointed person, just like all presidents are God’s anointed -- why didn’t you [evangelicals] throw your support behind him because it’s God will?” he asked.

Perry, a former Texas governor who ran against Trump in the 2016 Republican primary for president, grew up in the mainline United Methodist denomination, a church with a more liberal stance on some theological questions. He and his wife were active in a United Methodist church for years, including teaching confirmation classes. But in 2007, he joined a more conservative, evangelical megachurch.

His political message has often been overtly Christian, in ways both symbolic and tangible. He has said the country is based on Christian values and that his own political path has been directed by God; he has also signed antiabortion legislation while visiting an evangelical school and participated in constitutionally barred prayer at public school.

In Trump’s Cabinet, that puts him in good company. Many of Trump’s Cabinet secretaries are beloved by white evangelical voters, who sometimes have put aside their skepticism about Trump’s own moral compass because they saw the Christians he surrounded himself with.

Secretary of State Mike Pompeo recently was criticized by some and praised by others for promoting on the State Department’s homepage his speech, “Being a Christian Leader.” Perry said that he has attended a Wednesday morning Cabinet Bible study with a large number of secretaries, including Sonny Perdue, Ben Carson, Alex Azar, Alex Acosta (who resigned in July) and Betsy DeVos.

They do some business alongside discussing the Bible, he said.