MIAMI — In his first public appearance since the strike that killed Maj. Gen. Qassim Suleimani of Iran, President Trump rallied his evangelical Christian base of supporters on Friday, portraying himself as the restorer of faith in the public square and claiming that God is “on our side.”

Mr. Trump brought to the stage Cissie Graham Lynch, a granddaughter of Billy Graham, the founder of Christianity Today, to offer an implicit rebuke of the magazine’s recent editorial calling for his removal from the White House.

Ms. Lynch’s appearance underscored how sensitive Mr. Trump was about any signs of fracturing in his base; many evangelical allies denounced the editorial, and Ms. Graham Lynch vowed on Friday to help Mr. Trump win re-election. She then welcomed a supporter to the stage who told attendees that they could not trust what the news media wrote about the president.

Mentioning the attack in Baghdad only briefly, the president spent his hourlong speech at Ministerio Internacional El Rey Jesús, a church with a predominantly Hispanic congregation, alternating between his familiar mocking jabs at Democrats, who he repeatedly called anti-religious, and boasting about his own faith-based policies. Saying he would renew the importance of religion and family, Mr. Trump vowed that he would toughen restrictions on abortion and would take action to “safeguard students and teachers’ First Amendment rights to pray in our schools.”