BAGHDAD — Iraq’s Parliament chose an American-backed former intelligence chief as the new prime minister early Thursday morning, giving the country its first real government in more than five months as it confronts an array of potentially crippling crises.

The prime minister, Mustafa al-Kadhimi, 53, who has a reputation for pragmatism, was also seen as an acceptable choice to Iran, the other major foreign power competing for influence in Iraq.

Mr. al-Kadhimi is Iraq’s first real prime minister since the last one resigned in November in the face of persistent antigovernment protests.

He has already promised to take a new approach to the social unrest, meeting protesters and consulting with them rather than backing the previous government’s sporadic efforts to crush or ignore the turmoil.

But the protest movement that arose over government corruption and persistent joblessness last fall is no longer the government’s most pressing crisis. The coronavirus has frozen the economy. Oil and gas revenues, the government’s main source of income, are historically low.

And simmering tensions between the United States and Iran have played out in skirmishes on Iraqi soil that could turn into a wider war.

Plummeting energy prices have nearly halved Iraq’s operating revenue, making it likely Mr. al-Kadhimi will have to either cut salaries for government workers or drastically reduce their numbers in the next few weeks.

Either way, with the government as the country’s largest employer, the decision would have dramatic consequences.

It will also fall to Mr. al-Kadhimi and his advisers to determine when and how to reopen the economy and lift the curfews that have silenced the country’s cities in an effort to curb the spread of the coronavirus.

The virus appears to have had relatively little impact on Iraq. The country has registered about 2,500 cases, among the lowest in the region, but politicians and health officials are unsure whether those numbers would explode if they lift restrictions.

Although Mr. al-Kadhimi faces a litany of problems, his presence on the political stage signals a degree of flexibility in a political system that seemed deadlocked. The grip of Shiite political parties with religious ties may also be loosening.

Credit…Anmar Khalil/Associated Press

Since 2005, and the first elected government after Saddam Hussein’s removal, the country’s prime ministers have been from the Shiite Dawa Party, which has religious origins and close ties to Iran.

Mr. al-Kadhimi, whose political engagement was more secular, is thought to be more open to the anti-government protesters, many of whom have espoused anti-Iranian positions. He is also thought to be willing to protect them against the Iranian-backed militias that have previously attacked and killed them.

“With this prime minister, Iraq is breaking the cycle of having a prime minister who comes from political Islam. He is kind of a liberal, secular person,” said Rahman Jubori, a senior fellow at the American University of Iraq in Sulimaniya.

Realistically, however, Mr. al-Kadhimi will face strong resistance if he tries to directly confront the militias or take on the Shiite parties backed by Iran and their economic interests.

The Parliament remains the same as the one who supported the former prime minister, Adel Abdul Mahdi. And Mr. al-Kadhimi won approval for his government with the votes of the Fateh Coalition, the second largest in the Parliament, and which is made up of Shiite political parties that have close ties to Iran.

“We have an opportunity now to shake the system, we are not going to change the system, but we can shake it,” acknowledged Mr. Jubori, referring to Mr. al-Kadhimi’s willingness to consult with the protesters.

Mr. al-Kadhimi’s first real balancing act will be starting negotiations to reset the United States military mission in Iraq, as well as to figure out its commitment to working with Iraqis in other sectors, including health care and education.


Credit…Murtaja Lateef/EPA, via Shutterstock

In negotiating with the Americans, Mr. al-Kadhimi may have an advantage over a more pro-Iranian politician, said Michael Knights, a senior fellow at the Washington Institute for Middle East Studies.

“He can be tough with the U.S. in a way what no Iranian-backed candidate can be,” Mr. Knights said. “A candidate that the U.S. views with respect can get more for Iraq.”

And that could end up being important for Iran, which has been uneasy about the United States military presence just across the Iraqi border.

“If Kadhimi says to Mike Pompeo that he needs something, he needs it, the U.S. is open to making deals with him,” Mr. Knights said, referring to the American secretary of state.


Credit…Khalid Mohammed/Associated Press

Adding to the nation’s uncertainty about the near-term future is the coronavirus.

Mr. al-Kadhimi ultimately will have to decide when to fully open the government, for instance, and when to allow foreign airlines to resume flights to Iraq, a move that is important for business, but could also be hazardous.

Mr. al-Kadhimi has little experience in politics, and in his job as intelligence chief worked principally behind the scenes. That may work to his advantage, since he does not have much of a public profile for people to object to. But it is hard to know exactly how he will balance the pushes and pulls from the Iranian and United States governments.

He is close to many people in both the United States and Europe. He spent much of his life, after fleeing Iraq in 1985, in England or the United States, and was director of the Iraq Memory Foundation for seven years, which documented the atrocities of Saddam Hussein.

A native of Baghdad, he worked while in exile as a journalist, and has a law degree from a university in Baghdad.

In recent years he has been close to Barham Salih, who holds the job of Iraqi president, which has fewer powers than that of prime minister but which Mr. Salih has used to play a powerful, behind-the-scenes role. It was Mr. Salih, who has deep and longstanding ties to the United States, who nominated Mr. al-Kadhimi on April 9, after two other nominees failed.


Credit…Iraqi Presidency Media Office

Iran had objected to a previous pick, Adnan Zurfi, but sees Mr. al-Kadhimi as “the solution for now,” said Sheikh Salih al-Obeidi, a longtime spokesman and confidante of Moqtada al-Sadr, the nationalist, anti-American Shiite cleric who is also wary of Iran.

“With Kadhimi, there is no history,” Mr. al-Obeidi said. “He is the kind of person who has tried not to be against anyone.”

The United States seems genuinely committed to Mr. al-Kadhimi and quietly helped rally support for him by intimating to the Iraqi political factions that the United States would take several steps to help shore up the country, if the Parliament voted for Mr. al-Kadhimi’s government.