Baghdad (Reuters) - Already pressured by the U.S. withdrawal from the nuclear deal, Iran faces a major test in managing Shi’ite cleric Moqtada al-Sadr, a formidable opponent who beat Tehran’s longtime allies to achieve a shock victory in Iraq’s parliamentary election.

But If Tehran overplays its hand by squeezing Sadr out of a coalition government dominated by its allies, it risks losing influence by provoking conflict between Iranian-backed Shi’ites and those loyal to Sadr.

Populist Sadr all but won Iraq’s parliamentary election by tapping into growing public resentment directed at Iran and what some voters say is a corrupt political elite that has failed to help the poor.

But Iran is unlikely to relinquish influence in Iraq, its most important ally in the Middle East, and will push for a coalition that will preserve its interests.

“Iran will do everything in its power to remain strong in Iraq and to apply pressure,” said independent Iraqi analyst Wathiq al-Hashimi. “It’s a very critical situation.”

Before the election, Iran publicly stated it would not allow Sadr’s bloc - an unlikely alliance of Shi’tes, communists and other secular groups - to govern.

For his part, Sadr has made clear he is unwilling to compromise with Iran by forming a coalition with its main allies, Hadi al-Amiri, leader of the Badr paramilitary group and perhaps the most powerful man in Iraq, and former prime minister Nuri al-Maliki.

After the election results were announced, he said he would only cooperate with Prime Minister Haider al-Abadi, Kurds and Sunnis.

IRAQI POLITICS

Iran has manipulated Iraqi politics in its favor in the past, notably following the 2003 U.S.-led invasion that overthrew its enemy, Sunni dictator Saddam Hussein.

In the 2010 election, Vice President Ayad Allawi’s group won the largest number of seats, albeit with a narrow margin, but he was prevented from becoming prime minister. He blamed Tehran, which maneuvered Maliki into power.

On that occasion, Tehran overplayed its hand.

Critics said Maliki pursued a sectarian agenda which alienated Sunnis and created conditions which enabled Islamic State to seize one third of the country.

Blocking Sadr would also carry grave risks. His campaign resonated with millions of impoverished Iraqis, especially in his strongholds in Baghdad and Shi’ite heartlands.

Sadr derives legitimacy from a dynasty of Shi’ite religious scholars. He made his name leading two violent uprisings against U.S. troops following the invasion in 2003, while in 2016, he mobilized tens of thousands of supporters to storm Baghdad’s fortified Green Zone.

NO FOREIGN INTERFERENCE

Lawmaker Dhiaa al-Asadi, who heads Sadr’s bloc in the outgoing parliament, said they would seek alliances to counter any Iranian interference in attempts to form a government, and ruled out deals with Amiri or Maliki.

Iraqi Shi'ite cleric Moqtada al-Sadr visits his father's grave after parliamentary election results were announced, in Najaf, Iraq May 14, 2018. REUTERS/Alaa al-Marjani

“We don’t conceal our fear that there will be some intervention and meddling either by internal or external powers, and Iran is one of them,” he said.

He hoped political leaders had learned not to let Iranian interference dictate the election’s outcome.

Asadi said Sadr’s bloc would exert pressure through legal and democratic channels rather than in popular protests should Tehran try to influence the make-up of the government.

There is already bad blood between Sadr and Maliki, who as prime minister in 2008 cracked down on Sadr’s Mehdi Army militia in the southern city of Basra in a violent Shi’ite feud. More than 200 people were killed.

Sadr had pulled out of Maliki’s government the year before when the prime minister refused to set a deadline for U.S. troop withdrawals.

Renad Mansour, research fellow at Chatham House, said Iran would try to maintain its influence by working behind the scenes though allies such as Maliki and Amiri.

Iran may rely more heavily on Amiri, who spent two decades in Iran in opposition to Saddam and speaks Farsi. Through his Badr organization, he controls key positions in the interior ministry and security forces.

Sadr is likely to try and loosen the grip of Iran’s allies on the security services and other government institutions and seek a major government role.

Portraying himself as an Iraqi nationalist, Sadr has long opposed foreign interference, whether by American invaders or Iranian proxies.

Strife could be avoided if Sadr enters into an alliance with Iranian-backed parties which would offer him a cabinet post, former foreign minister Hoshyar Zebari said.

“He might be given a major ministry, like interior or foreign, in return for stepping back. Sadr would meanwhile form an opposition bloc in parliament,” Zebari said.

But that seems unlikely and it is unclear how Sadr will use his election victory.

Always unpredictable, he opposed Iranian influence but went into self-imposed exile there. Then in 2003, he appeared out of the blue and assembled a militia to fight the Americans.

A Western diplomat described him as “very hard to read”.