Adel Abdel Mahdi, 77, came to power last year as the product of a tenuous alliance between populist cleric Moqtada Sadr and pro-Iran paramilitary chief Hadi al-Ameri, with the required blessing of Iraq's Shiite religious leadership.
He was seen as an almost professorial figure who could tackle unemployment and government graft as Iraq's first prime minister since the defeat of the Islamic State group.
Most observers expected summer protests would put an early end to his mandate, and even he said he had his resignation letter "in his pocket."
So when popular demonstrations erupted in early October over corruption and lack of jobs, the premier readied a resignation speech to deliver live on television, three government sources told AFP, requesting to remain anonymous.
He never gave it.
"He was fully intending to resign during the first week of protests -- but stayed under pressure from the different factions," one of the officials said.
Instead, Abdel Mahdi appeared in a stern pre-recorded address that aired around 2:00 am on October 3, proposing a package of reforms that protesters angrily dismissed as insufficient.
He has since resisted intensifying calls for him to step down and for the political system to be overhauled, adopting a noticeably tougher stance towards the demonstrators.
"The premier is shackled by the political parties that brought him to power," a second official said.
'In a bubble'
The first week of rallies ended with at least 157 people dead, most of them protesters shot dead in Baghdad, according to a government probe.
After a two-week lull for the Shiite Arbaeen pilgrimage, protests resumed on October 24.
Sit-ins shut down public universities, provincial government offices and main streets, with protesters shrugging off the proposed reforms.
But Abdel Mahdi said they were being used as "human shields" by "infiltrators."
"He's in a bubble, and being told that the protests are a conspiracy against his government and that he should stay in power. He's started to believe it," one official said.
Two government sources said the premier was no longer communicating with President Barham Saleh, seen as his top ally in the absence of his own popular base.
"Saleh was the first one to suggest finding an alternative to Abdel Mahdi, and their ties got worse after that," one of them said.
The president has hosted meetings with leading politicians to set out a roadmap to an snap general election, which would pave the way for a new prime minister.
But Abdel Mahdi on Tuesday dismissed the idea of an early election.
"He thinks that if he goes down, everyone should go down with him," an Iraqi official said.
Others said he was also under growing pressure from Iran and its Iraqi allies, who pushed him to sideline several military commanders seen as close to the US.
That pressure intensified with the arrival of Qasem Soleimani, the head of the Iranian Revolutionary Guards' foreign operations arm, shortly after the protests began.
Suleimani has held meetings in Baghdad and Najaf to convince top party officials to close ranks around the current government.
"He's calling the shots," one official told AFP.
'Victim of infighting'
A second official said Abdel Mahdi "is not in a position to push back against Iranian influence".
"He knows if he does not follow the Iranian line, he will be forced out and then blamed for what is going on," he said.
Abdel Mahdi has made several televised addresses and publishes online statements on a near-daily basis, even as his government imposes internet restrictions in most of Iraq.
After first offering to resign if political factions agreed on a replacement, he has since hardened his stance.
On Tuesday, he said a caretaker government would not have the authority to sign much-needed contracts.
Officials said a consensus was forming that would keep him at the helm of a transitional government, but he was likely to remain paralysed politically.
Iraqi analyst Issam Faili said the divisions would continue to hamstring any "independent decision-making."
"If you have a broad and solid political base, then you have room to manoeuvre," Faili said..
"Abdel Mahdi is the victim of all the infighting around him."