The American diplomat Brett McGurk is the central player in the seventy-two-nation coalition fighting the Islamic State, a disparate array of countries twice the size of NATO. He has now worked all of America’s major wars against extremism—in Afghanistan, Iraq, and Syria—under three very different Presidents: George W. Bush, Barack Obama, and now Donald Trump. McGurk served in Baghdad after the ouster of Saddam Hussein; he used his experience clerking for the late Chief Justice William Rehnquist on the Supreme Court to help draft Iraq’s new constitution. President Bush brought McGurk back to Washington to serve on the National Security Council and help run the campaign against Al Qaeda. President Obama tapped him to work Iraq and Iran at the State Department. McGurk was visiting Kurdistan, in northern Iraq, when ISIS seized nearby Mosul. In 2015, he became Special Presidential Envoy for the Global Coalition to Counter ISIS. President Trump kept him on.

In a sign of how fast the Islamic State is shrinking, McGurk last month visited northern Syria. I called on him Wednesday, at his small whitewashed office on the ground floor of the State Department, to assess the future of ISIS and the world’s most unconventional nation. McGurk is an optimist, long-term, despite the chorus of skeptics in Washington about extremism, Iraq and Syria, and U.S. foreign policy in the volatile Middle East. The interview has been edited and condensed. McGurk’s most chilling answer was when he talked about how many ISIS fighters are still alive.

Where is ISIS? The leaders? The fighters? Intelligence assessments claim that at least twenty per cent of the fighters have returned to their countries of origin, with some exceptions like Britain, where it may be as high as fifty per cent. Where are they going as they face defeat?

We had forty thousand foreign fighters come into Syria from over a hundred and ten countries, as far away as China. The reason Mosul was so difficult in the final three weeks of battle was because we had hundreds of foreign fighters in the Old City barricaded in civilian structures. Our guys could hear them on the radio speaking Chinese, Russian, Dutch, French.

Did some foreign fighters get out before we had the borders sealed? Yes. Now it is extremely difficult. Foreign fighters who are in Iraq and Syria are going to die in Iraq and Syria. Mosul is now finished. Raqqa is surrounded.

[The American-backed] Syrian Democratic Forces have cleared about forty per cent of the city. [ISIS fighters] are concentrating now in small towns along a little span of the Euphrates River that crisscrosses the Iraq and Syria border in the middle of nowhere. These guys used to plan major attacks in Raqqa, with the infrastructure of a city, and then send teams to conduct attacks in Paris and Brussels. They can’t do that anymore.

How many ISIS fighters are still active? And where?

Our experts think the active cadre of ISIS fighters is down to twelve thousand total fighters, local and foreign. The Syrian Democratic Forces, the force we are working with, is incredibly brave. They are going into these high-rise buildings, room by room, floor by floor, to root these guys out.

Is Abu Bakr al-Baghdadi, the ISIS caliph, alive? And what is he doing?

This is someone who cannot show his face. He communicates by audiotapes, like we are back in the nineteen-nineties. He has dramatically tainted his claim to any legitimacy. Whether or not he is alive, we do not know. But his command and control over this organization is severed.

What is the U.S. military role after the caliphate collapses?

Our coalition has trained a hundred thousand members of the Iraqi security force that had collapsed in 2014. They have now fought some of the most difficult battles since the Second World War. We are in discussions with the Iraqi government about a future role for the coalition training and advising. In Syria, we have also pioneered this model of working by, with, and through local forces. It’s local Syrians retaking their areas. Our footprint is small, it’s light, but it is effective. We will want to be able to keep the pressure so that ISIS can’t regenerate.

So air strikes will continue?

If we see an ISIS leader or something, we will retain the right. In this campaign, coalition-enabled operations have cleared out a total of sixty thousand square kilometres [roughly twenty-three thousand square miles]. We liberated almost five million people. ISIS has not retaken a single square kilometre. This is not the day when you go clear, but can’t hold, and the enemy comes back. The model that we are using appears to be sustainable.

So, is ISIS going to come back? They’ll always be around as small terrorist cells. We want to make sure the Iraqis are able to handle that. But in terms of ISIS being able to regenerate as a force that can take and seize territory as it could in 2014, I just don’t think they’ll ever retain that capability.

Fourteen years after the U.S. intervention, in 2003, Iraq still does not have a political deal to share power among sectarian and ethnic factions. How does Iraq solve an issue as important to the future of the country as the military campaign?

I resist the notion that because there wasn’t some political deal in Baghdad, the Sunnis decided to put their lot with ISIS. That is simplistic. ISIS came into Sunni areas and anyone who didn’t agree with their twisted vision was murdered. Sunnis were the largest victims of ISIS.

The government of Iraq has a policy of decentralization, empowering people at the local level to restore life to their communities. Iraq will have an election, probably in May of next year. The divisions in Iraqi society now are not so much Sunni-Shia. There are big divisions among the different Shia groups and inter-Sunni. Frankly, some Sunni tribes sided with ISIS in 2014. In these communities, there isn’t a get-out-of-jail-free card.

There have been a lot of revenge killings.

Probably not as many as had been predicted, but yes. It’s impossible to have a totally clean aftermath.

Prime Minister Haider al-Abadi said that the Popular Mobilization Forces, predominantly Shiite militias, weren’t allowed in Mosul, but I saw their pickup trucks—with big flags waving sayings from the Quran—all over town. How much of a concern is the unleashing of the P.M.F., now and down the road?

The P.M.F. arose from a fatwa issued by Grand Ayatollah Ali al-Sistani in the worst days of 2014, when it looked like Baghdad could fall. He issued a fatwa for able-bodied males to help save the country. About eighty per cent have proved to be quite disciplined; they operate under control of the state. About twenty per cent of them are not. That includes some Shia militia groups. It also includes some Sunni groups that have discipline problems. Given the terrain that Iraq had to cover during the Mosul campaign, there was some necessity for the Popular Mobilization Forces. This is an issue that the Iraqi government has to get its arms around.

Since 2003, Iran has played an increasing role in Iraq. How do you assess their intentions down the road and their power compared to the U.S.?

Iran likes to be flattered with the view that everything that happens in Iraq and Syria happens because Iran is pulling the strings. That’s just not true. Do they have enormous influence? Yes. Just look at a map and you can understand why. But the differences, even within the Shia community in Iraq and the Shia community in Iran, are profound. The vision of [Iraq’s] Grand Ayatollah Sistani —of quietism and a civil state, meaning not a state governed by clerics—is totally different from the vision of [Iran’s] Supreme Leader Ali Khamenei. The Iranians tried to do a number of things in Iraq that simply have not worked, because the Iraqis rejected it. Their influence is not dominant. I never discount the ability of the Iraqis to chart their own course.