Reuters

The Islamic State indulged in some of the most ostentatious brutality and sadism of recent decades. If any extremist group deserves the adjective evil, this would be it. But it is precisely our disgust, which ISIS has well earned, that makes it difficult to talk about what the group was and what it meant—and what it may still mean.

The Washington Post was mocked for describing Abu Bakr al-Baghdadi as an “austere religious scholar” in the headline of its obituary after the ISIS chief was killed on October 27. (The headline was later changed.) Donald Trump Jr. tweeted that the Post and other mainstream outlets had “harsher criticism for the President of The United States than they do for the leader of ISIS, a known serial rapist and murderer.” He kind of had a point.

Similar criticisms were lobbed against Rukmini Callimachi and Falih Hassan, the authors of a New York Times story about Baghdadi’s death, for describing various government services that ISIS provided in the parts of Iraq and Syria that it once controlled. “The Islamic State collected taxes and saw to it that the garbage was picked up,” they wrote. “Couples who got married could expect to receive a marriage license printed on Islamic State stationery. Once children of those unions were born, their birth weight was duly recorded on an ISIS-issued birth certificate. The group even ran its own D.M.V.” Patrick Osgood, a researcher focusing on Iraq, said on Twitter that the Times story’s “emphasis is utterly wrong, privileging ISIS marginalia over a true reckoning of immense human cost—genocide, multiple massacres of 100s, 1,000s missing, ruinous war—of [Baghdadi’s] fetid ambition.”

The concern is understandable. Perhaps talking about ISIS in terms of how it governed rather than how many it killed might provide it with a sheen of legitimacy after the fall of the group’s so-called caliphate. But those wishing to focus almost entirely on the Islamic State’s awfulness—to the exclusion of what made it successful—are falling into an analytical trap. After all, most Americans are presumably already aware that ISIS was a terrorist organization that did terrible things, so it’s not as if highlighting ISIS’s savagery, sex slavery, and killing of innocents fills an important gap in the public discourse. (Anyone unaware of this horrifying record is unlikely to be a reader of The Washington Post or The New York Times in the first place.) But, more important, one can recognize the extent of ISIS’s brutality while also dispassionately discussing its relative effectiveness in certain aspects of governing. The bar for what counts as good governance in Iraq and Syria is quite low.

In 2015, at the height of the group’s savagery, academics and experts did considerable work on how ISIS administered the areas it ruled. The logic was simple: The only way to prevent similar groups from emerging in the future was to understand what made ISIS distinctive. ISIS didn’t come out of nowhere. There were reasons it was able to capture as much territory as it did. And the “marginalia” of governance was part of that story. This can be a blind spot. Western observers assume that brutal groups are bad at governing. This is true sometimes, but the opposite can also be true: The more brutal groups are better at it than the less brutal ones. As Yale’s Mara Revkin explained in perhaps the definitive account of how ISIS governed:

Media coverage of the Islamic State frequently refers to the group’s violent and seemingly archaic justice system without considering the institutional structures that enable this violence, or the broader function that it serves in the group’s ambitious state-building project. Legal institutions make it easier for the group to capture and retain territory by legitimizing its claim to sovereignty, justifying the expropriation of the property and land of enemies, and building goodwill with civilians by ensuring accountability.

The notion that we should call ISIS the worst names we can muster and leave it at that is to set ourselves up for future failure. And that is worth worrying about, since there will be attempts to replicate ISIS’s governance model in the coming decades—even if that seems unlikely in the aftermath of the group’s recent defeats. But we don’t even need to wait. Right in front of us, as we speak, is an example of an extremist group—the Taliban—that effectively mixes brutality and “good (enough) governance” in Afghanistan.

If ISIS were merely a bunch of crazies and thugs going around killing people, it would have been easier to defeat. Its fighters wouldn’t have been able to march through large swaths of Iraq and Syria, handily defeat U.S.-trained security forces, and enjoy, at least in the beginning, the acquiescence and even support of segments of the local population. How was ISIS able to do this?

Unlike most terrorist groups, ISIS had a distinctive interest in state-building, an interest reflected in the group’s propaganda. One 2015 study found that about 45 percent of ISIS media outreach focused on building and sustaining the caliphate, with messaging on “traffic police, charity work, judicial systems, hospitals and agricultural projects.” At the time, there was little to suggest that this would be sustainable. As Will McCants, author of The ISIS Apocalypse, once described it to me, “The caliphate may require caution, but the apocalypse requires abandon.” And, indeed, today the caliphate no longer exists. But it did exist.

Before anything else, a state—or an organization that wishes to approximate a state—must be able to provide some degree of law and order. Without order, there cannot be law, and ISIS’s project was very much about law. ISIS got its biggest break with the collapse of governmental authority in Syria and Iraq in the post–Arab Spring period. The extremist group could do what discredited governments couldn’t: provide Syrians and Iraqis with a degree of security, which is what they came to crave the most. A Syrian in, say, Raqqa—which had been ISIS’s de facto capital—might have detested the group’s ideology but still supported its rule over the alternatives, because having some security was preferable to having none.

Here, oddly enough, ISIS’s absolutism was a feature rather than a bug. Terror and state-building went hand in hand. After a country collapses and descends into warring factions and rampant criminal activity, any group that hopes to reconstitute order must assume a monopoly over the use of force. This means defeating any pretenders to the throne. In an already brutal war zone, brutality can, unfortunately, work. Instilling terror in the hearts of your opponents undermines their morale, making them more likely to stand down, flee, or surrender on the battlefield.

Once territory is captured, what comes next? More challenging is channeling the focused brutality of battle into actual governing. Yet, in fairly quick order, with the international community paying little attention, ISIS began setting up well-developed institutional structures. The elaborate legal structures—oriented around interlocking Sharia courts, binding fatwas, and detailed tax codes—reflected a serious effort to institutionalize a new order, in what Revkin and the political scientist Andrew March term “scrupulous legality.”

With this in mind, it becomes somewhat easier to understand how some residents—in a region that has long lacked law, order, and government services—might have gone along with or at least remained neutral toward ISIS rule. In Iraq, Sunni populations had found themselves marginalized or worse. In Syria, civilians routinely suffered atrocities under Bashar al-Assad’s dictatorship, which, in terms of the sheer human toll, was more brutal and destructive than ISIS ever could have hoped to be. By that standard, ISIS rule may have seemed like an improvement. Of course, it would be a mistake to overstate the level of governance that ISIS actually provided. It didn’t practice good governance so much as as less bad governance, and that can be good enough. As long as you’re able to present yourself as a somewhat better alternative to absolute chaos or sectarian repression, then you can hold on to power—not necessarily in spite of brutality but because of it.

It matters that many people prefer cruel governance to no governance, and, whether we like it or not, it will always matter in places where governments are weak and lack legitimacy. The Taliban seemed defeated after the initially successful U.S.-led invasion in Afghanistan in 2001. That status didn’t last. In the mid-2000s, under President Hamid Karzai, and with corruption and governance failures mounting, the Taliban moved to fill the gap by providing free mediation of tribal and criminal disputes. Afghans soon reported surprising levels of satisfaction with Taliban verdicts in local courts, as my Brookings Institution colleague Vanda Felbab-Brown has detailed in her fieldwork in Afghanistan, and as a leaked report of interviews of Afghans detained by the U.S. military in Bagram also documented.

In his remarks on the death of al-Baghdadi, President Donald Trump, drawing a contrast with his predecessor, used language with the apparent aim of sounding tough. He referred to ISIS fighters as “frightened puppies.” Trump noted that “we obliterated his caliphate, 100 percent, in March of this year. Today’s events are another reminder that we will continue to pursue the remaining ISIS terrorists to their brutal end.” But Trump has said almost nothing about how he envisions preventing ISIS-like groups from emerging in the future. This would require more than bravado. In this respect, Trump’s vision for fighting terror, to the extent he has one, is weak and incoherent.

In fairness, Trump is building on President Barack Obama’s “counterterrorism first” policy, in which terrorism was dealt with in a void—as if groups like ISIS or al-Qaeda fall from the sky, out of place and out of time. But they are very much products of their context. This should be obvious enough: The two countries where ISIS gained the most territory were the two countries most plagued by civil war and governance vacuums. What if the true cause of instability in the Middle East is precisely the absence of legitimate authority, a problem the Trump administration seems to have little interest in talking about?

As the Middle East analyst Kenneth M. Pollack has written, emphasizing counterterrorism “as a goal of foreign policy” gets something rather fundamentally wrong about, well, counterterrorism. The emergence and growth of terrorist groups in particular places at particular times is a product of other factors, and those other factors will have to be addressed at some point. You cannot fight terrorism just by fighting terrorism, and to think that you can is an illusion that has long hobbled U.S. policy in the Middle East and South Asia.

The irony is that Americans’ willingness to think seriously about the sources of ISIS’s appeal seems to erode as the group and its now-deceased leader recede into memory. One might hope the opposite would occur—that with critical distance from the events themselves, we might be better able to assess what went wrong the last time around. The killing of Baghdadi is no doubt a success, but self-congratulation will take us only so far—and not nearly far enough.

We want to hear what you think about this article. Submit a letter to the editor or write to letters@theatlantic.com.