WASHINGTON — President Trump’s embrace of anti-government protesters in Iran is other departure from his predecessors, who feared such overt support could backfire and inadvertently help hard-liners in the Islamic Republic.

Trump has tweeted repeatedly in recent days in support of protesters who surged into the streets in anger over the apparently accidental downing of a Ukrainian jetliner and their government’s initial attempt to conceal its role in the disaster.

But his encouragement carries a risk by seeming to confirm the claims of Iranian hard-liners who accuse the U.S. of fomenting the unrest.

“When the Iranian people are upset with their government for blatantly lying about shooting down a plane, he should have taken the high road and send his condolences to the families,“ said Jon Alterman, director of the Middle East Program at Center for Strategic and International Studies. “By seeming to make it about him, he delegitimizes the protesters and allows the government to portray the protests as a U.S. plot.“

Previous administrations have sought to keep some distance between Washington and demonstrators opposed to Iran’s Islamic leadership. That was why the Obama administration offered only muted expressions of support during the major political unrest in Iran in 2009.

Trump and his team have no such qualms. They see their pro-demonstrator comments — even the president’s tweets in Farsi on Sunday — as a way to further pressure Tehran.

Popular anger swelled Monday in Iran over the downing of the Ukrainian jet, which was apparently knocked out of the sky by an Iranian missile hours after the Islamic Republic fired a barrage of missiles at Iraqi bases housing American soldiers. Iran’s action was in response to the U.S. killing of its top military leader, Gen. Qassem Soleimani, in a drone strike.

Ebrahim Raisi, the head of Iran’s judiciary, issued a warning to protesters, saying “the agents of America and agents of foreign countries” want to use anger over Flight 752 to “compromise” Iran’s security. Iran often blames anti-government protests on foreign conspiracies.

In a series of tweets sent since late last week as protests against Iran’s shooting down of a Ukrainian passenger jet intensified, Trump has personally exhorted the Iranian people to rise up and be heard.

Matthew Lee and Deb Riechmann are Associated Press writers.