In the wake of the terrorist attacks in and around Barcelona, clichés about radicalization are again making the rounds. For some, the twelve young members of the cell behind the Barcelona attacks, all men, were “brainwashed”; for others the blame falls on the town of Ripoll for becoming a “terrorist breeding ground”; for others yet it’s Islam as a whole that must be held accountable. For those who study radicalization and terrorism, all of these explanations fall short.

The greatest difficulty for our ability to understand and respond to terrorism and radicalization is linear thinking. Arguing that radicalization is caused by poverty because most modern jihadists come from marginalized neighborhoods is the same flawed logic as arguing that radicalization is caused by Islam because jihadists are all Muslims. Even combining Islam and marginalization as risk factors doesn’t get us far, as only a fraction of a percentage of marginalized Muslims join jihadist groups. One can add many more factors and still end up with the same dilemma. Trying to find a root cause of radicalization is doomed from the start because it assumes a single, linear chain of causation.

Instead, it is better to think of radicalization as a phenomenon in which the whole is greater than the sum of its parts. Multiple factors interact in complex ways that cause radicalization to emerge in individual people and groups. As with other complex systems, such as ecosystems, removing one factor does not cause the system to collapse but instead to evolve in ways that may be positive or negative. In the jihadist movement there have been many small tipping points, including the USSR invasion of Afghanistan in 1979, the 2003 US invasion of Iraq, and the Syrian civil war of 2011—each of which mobilized a new generation of fighters.

Profiles of jihadists have evolved over the years. Generally, revolutionary movements attract different kinds of recruits at different stages in their development. Many of the founders and leaders of the modern jihadist movement were educated members of the upper-middle or upper classes. Even many early foot soldiers were of above-average socio-economic status. Research on recruits to jihadist groups using data from the 1970s to 2010 found that members of these groups were six times more likely than the general population to have a bachelor’s degree. In the Middle East, engineering schools are often the most competitive programs and only take the best and brightest students; jihadists were seventeen times more likely to have an engineering degree.

New recruits to al-Qaeda spent months or even years at training camps, where they were vetted by leadership for their mental stability and ideological purity. This vetting even applied to relationships among leaders. When the billionaire Osama bin Laden started to expand his network, he was selective about the social caliber of people he chose to ally himself with. In 1999, when he met Abu Musab al-Zarqawi, the founder of what would become ISIS, he was suspicious of him not only for his extremist beliefs in apostatizing moderate Muslims, but also because of Zarqawi’s criminal past.

But criminal pasts would eventually become a standout feature of European jihadists venturing toward Syria and Iraq. According to one study of a small database of European jihadists, 57 percent of eventual Syria-bound jihadists had a petty or violent criminal past. Studies of Syria-bound foreign fighters from Norway and Germany found that they were overwhelmingly from lower socio-economic backgrounds. Many recent European radicalization “hotspots” are neighborhoods known for their high rates of unemployment and crime. ISIS propaganda geared toward Europeans alluded to these criminal pasts by offering jihad as a form of redemption, claiming that “sometimes people with the worst pasts have the brightest futures.”

The evidence that early al-Qaeda members were more educated, psychologically stable, and ideologically grounded is consistent with a group in the early period of a movement’s development, consisting of self-organizing networks operating clandestinely. Nascent decentralized groups rely on a reputation for success as the prime attractor for new adherents. Failing at an attack would be embarrassing and costly, and therefore only the best and brightest should be entrusted with such a duty.

On the other hand, ISIS operated like a traditional military in carrying on a local insurgency. It held and governed land in a way that al-Qaeda never did, and this loosened its stringency regarding recruits. The group sucked up fighters from areas under its control with promises of money and power, and appealed to the downtrodden of the Muslim diaspora to join their cause. Ideological purity, education, and law-abiding pasts took a back seat to the need for soldiers. If al-Qaeda, with its careful vetting and training, was the special forces of the jihadist movement, then ISIS was the infantry.

But as ISIS’s goals continued to evolve so too did their recruits. Few women from Europe ventured to Syria in the early days of the conflict, but by 2014 one in seven European foreign fighters were women, and by 2016 that number had jumped to one in three. Women didn’t become more vulnerable to radicalization over that period—instead, they were targeted for radicalization. Until 2014, ISIS’s local insurgency demanded mostly young men of fighting capacity and thus had little need for women. In June 2014, ISIS declared its so-called Caliphate and shifted its focus to state-building. In order to legitimize that state, the immigration of women, children, and families was explicitly sought after. Once the women arrived they began recruiting female friends, family members, and strangers over the Internet to pull in more “lionesses,” as they were often called, leading to the jump seen in 2016.

Since ISIS’s caliphate began collapsing in early 2016, they have been further expanding the use of other types of recruits. Women have planned to carry out attacks, new converts to Islam with no previous radical ties (known as “clean men”) have been alleged to be go-betweens connecting aspiring attackers with ISIS core members, lone actors (who have a greater instance of mental illness than group actors) have been inspired or directed to attack, people both younger and older than the norm have been recruited. The organization is exploiting all the resources at its disposal to maintain its strength in the eyes of its supporters.

These changes in patterns of recruitment show that profiles of recruits reveal more about changes in conflict dynamics than about the psychological vulnerabilities of certain demographics. Disaffected youth or marginalized communities may have been convenient targets for recruitment in recent circumstances, but long-term strategies for the prevention of radicalization must look beyond these current dynamics.

In addition, well-meaning policies that can be perceived as profiling run the risk of alienating the communities involved, as has been seen with the UK’s “Prevent” strategy. But even when we focus on a narrow range of times and locations it is hard to detect a pattern. The core members of the Paris-Brussels terrorist network were mostly petty criminals from a marginalized neighborhood in Brussels. The Barcelona attackers were well-integrated youth from a culturally cohesive rural town. What they do have in common is that they were both groups of siblings and childhood friends.

As the structures of terrorist organizations evolve so too do their recruitment methods. In failed states, such as Syria, groups take on a hierarchical “command-cadre” structure, which resembles a formal military and allows the group to operate openly while providing security and governance in the area it controls. For some inhabitants of such areas, joining them may be more a matter of practicality than of conviction. In developed nations, such as in Europe, terrorist groups must operate clandestinely and thus take on a “network” structure. Networks are self-organizing, though they often contain charismatic leaders who pull together disparate individuals and small groups of friends.

Prior to the US invasion in 2001, al-Qaeda had begun to achieve a small-scale command-cadre structure in Afghanistan. It had a limited leadership structure and many hundreds of graduates from its training camps. The al-Qaeda leadership were hosted in Afghanistan by the Taliban and so they operated more like a venture capital firm, to which members of its various international networks would come to seek training, funds, and contacts.

European recruits of al-Qaeda in the 1990s and 2000s were often small groups of friends who would co-radicalize each other and then seek out opportunities to train in foreign camps. In a 2009 multi-nation study, researchers found that 75 percent of al-Qaeda members were recruited by a friend, 20 percent by a family member, and only 5 percent by a stranger. This recruitment pattern is what would be expected for a funding, plotting, and training structure like al-Qaeda that was waging a global jihad.

By contrast, the jihadist groups in Syria were waging a local insurgency and were setting up multiple command-cadre structures. In addition, by this time a series of prolific recruiters had gained a foothold in Europe. The hierarchical structures in Syria were able to work in tandem with their networks in Europe to create a mix of top-down and horizontal recruitment. For example, by 2015, nearly one in three Belgian foreign fighters in Syria were recruited by just two people: Khalid Zerkani and Fouad Belkacem. Some of those recruits then recruited their friends, which led to a social domino effect of radicalization.

Much radicalization is this phenomenon of friends recruiting friends. Preliminary findings on Western ISIS fighters indicate that very few recruits were self-radicalized; for the vast majority, radicalization was facilitated through social interaction. The Internet can facilitate this, but the existence of very specific geographical hotspots that produce the bulk of jihadists indicates that, when it comes to recruitment, offline factors are more important than the Internet. The picture emerging of the Barcelona attackers is more typical of radicalization in Europe. A charismatic leader, in the form of a radical imam, began to groom at least four sets of brothers and close friends, who then further co-radicalized one another.

Anybody can be exposed to new moral beliefs but when those beliefs become part of the day-to-day conversations of your friends, they have a greater chance of being acted upon. A common belief about those who join violent groups is that they are looking for brotherhood or sisterhood, and those groups certainly do offer that. But often it is in fact a pre-existing sense of belonging that is the risk factor. When radical ideas get introduced into tight-knit networks of friends, these groups act as echo chambers that reinforce those beliefs. The beliefs then act as a social glue that brings the friends closer to one another as a group, and distances the group as a whole from the rest of society.

As this process continues, the values become sacred and the identities of the individuals become fused with the group. Indeed, field studies by Artis International—a consortium of researchers and practitioners studying violent conflict, of which I am a part—of residents in two radicalization hotspots in Morocco show that it is the combination of holding a sacred value and being closely connected with your group of friends that motivates people to fight and die for their values. Strong identification with close comrades was a principal determinant of willingness to sacrifice oneself, a University of Oxford study found, among Libyan revolutionaries fighting the Qaddafi regime in 2011. My own studies on jihadist-group sympathizers in Paris and Barcelona show that, contrary to what many people believe, identification with Islam or the Muslim ummah (worldwide Muslim community) does not strongly predict willingness to fight and die for jihadist ideals. Instead, transcendent beliefs shared with close friends increased willingness to commit violence.

Most prevention policies aim to stop radicalization for every single person. This is a tall order and unlikely to succeed. A more evidence-based approach would be to try to mitigate group radicalization. Values and beliefs are socially embedded. Once the social setting changes, the beliefs may lose their grounding. For this reason, friends are not only crucial for the radicalization process but can be important in the prevention and de-radicalization process as well. Prevention, de-radicalization, and reintegration programs in Germany, Sweden, Denmark, and Sri Lanka have all used moderate friends and family members to pull a person away from violent extremism.

The existence of hotspots of radicalization can perhaps best be understood using epidemiology. When tracing back the origins of local European networks we often find a “patient zero” who is the first person to bring radical ideas into a community. This could be a recruiter, a radical imam as in the case of Barcelona, or any other person with the propensity and skills to spread extremist ideas. The rate of propagation of these ideas may partly be attributable to the sheer number of vulnerable individuals in those areas, though, again, it’s often friends and family members who act as catalysts between the ideas and new adherents. The rate of propagation may also be due to the bystander effect, whereby non-radical individuals do not report suspicious behaviors. This effect can be enhanced by rampant social disorganization in certain neighborhoods. If areas are already heavily afflicted by petty or organized crime, drug-dealing, or vandalism, then residents habituate to a level of nefarious behavior in their midst. This can be seen as a weakening of the community immune system, which in more organized areas would detect and expel the intruding ideas at an early stage.

Reducing social disorganization in certain communities may help increase their resistance to extremism. But bombarding radicalization hotspots with counter-radicalization programs—which often involves getting teachers, social workers, or community leaders to report on those they oversee—can make residents of those areas feel suspect, which may do more harm than good. Economic development may not be effective either. Southern European countries, such as Spain and Italy, have worse economic integration of their immigrant populations than do northern European countries, such as Sweden, Denmark, Germany, or the UK. Yet the northern European countries have higher per capita radicalization rates than the southern countries. Economic development of certain communities should be welcomed but it may not be the most effective strategy for preventing young men like the well-integrated Barcelona attackers from radicalizing.

Working directly with the non-radical friends and family members of those on terrorist watch lists avoids the pitfalls of other approaches. In most cases, non-radical friends and family have no idea their loved ones are on watch lists, and if they do, don’t know how to intervene. Programs that help facilitate this interaction could be successful.

Radicalization is a complex system that cannot be reduced to its individual factors. International conflicts, social networks, community, ideology, and individual vulnerabilities all combine to let radicalization emerge. Some of these factors may be more volatile, such as individual personalities, while others are more stable, such as social networks. But only a holistic view of this phenomenon can provide the understanding needed for designing policies to counter the pull of extremist groups.