During his lunch break one day at the end of March, Dirk Sauerborn, a senior police officer in the German city of Düsseldorf, agreed to appear on a children’s television program called Nine ½, which was devoted that week to the subject of terrorism. In their tagline for the episode, the show’s producers posed a question about the bombings that had struck a week earlier in Brussels, leaving more than 30 people dead. They asked: “Who would do such a thing?” It fell to Sauerborn to provide an answer that German kids could understand.

For him this was part of the job. Tall and lean, with grey sideburns and a rigid posture, Sauerborn runs a police outreach program called Wegweiser, or Signpost, whose aim is to prevent the radicalization of Muslim youth. The program was created two years ago to counter the online recruitment efforts of the Islamic State of Iraq and Greater Syria (ISIS), the terrorist group that has claimed responsibility for the Brussels bombings and the related attacks in Paris last November.

In looking for targets – or as Sauerborn calls them, “clients” – the program has found itself in direct competition with ISIS for the hearts and minds of European Muslims. On Friday, authorities in Belgium arrested two more suspects in connection with the Brussels bombing. Both of them are Belgian citizens reportedly radicalized while growing up in a poor, immigrant neighborhood of Brussels – exactly the type of men Sauerborn tries to steer away from radicalism before they turn violent.

“We work on prevention,” he told me recently at the Signpost headquarters in Düsseldorf, a grey office sparely decorated with Islamic prayers and inspirational posters. “We approach young people who are thinking about it, who are playing with the idea of going to Syria” to join ISIS, he says. “We give them a mechanism to judge what they are hearing in the ISIS propaganda, and to say, ‘Hey, this can’t be right.’”

It is difficult to gauge the impact of these efforts, in part because, as Sauerborn puts it, “prevented crimes do not show up in the statistics.” But judging by one important measure – the number of Germans who have died in Islamist attacks on German soil – the authorities seem to be doing something right; that number currently stands at zero.

This doesn’t mean Germany is immune to Islamic radicalism. The terrorist cell behind 9/11 was based in the German city of Hamburg, and its ringleader Mohammed Atta is thought to have masterminded the plot from his apartment there. But in the 67-year history of the Federal Republic of Germany, only one homegrown jihadist has ever managed to kill anyone inside the country. His name is Arid Uka, a lonely young man from Kosovo who was radicalized online and, in the spring of 2011, shot two U.S. servicemen dead at an airport in Frankfurt. No German citizens died in that attack, nor in any other act of Islamist violence that has ever taken place in Germany.

Among the larger nations of Western Europe, that record is unique. And it seems even more remarkable when you consider that Germany, even before the arrival last year of more than a million asylum seekers from the Muslim world, had the largest Muslim population in the E.U., numbering 4.8 million as of 2010.

France, by comparison, has almost the same number – 4.7 million – but its problems with extremism have been far worse. There have been at least six deadly Islamist attacks in France since 2012, killing a total of 160 people — including the 130 killed in Paris last November, when ISIS militants went on a citywide rampage.

From across the border, Germans have watched the death toll climb with a sense of foreboding. In a nationwide poll conducted in December, two-thirds of respondents said they expect an ISIS attack in Germany at some point this year. While traveling abroad, Germans have become victims of ISIS; eight German tourists were among the dead in an Istanbul bombing in January that was claimed by the extremist group. But so far their country has somehow managed to avoid such violence on its territory. “It has been a lot of luck,” says Hans-Peter Friedrich, a former Interior Minister in Chancellor Angela Merkel’s government who oversaw the national police from spring 2011 to late 2013.

To some extent, luck does help explain Germany’s record with terrorism. In December 2012, for instance, a bomb left in a gym bag at a train station in Bonn, the former capital of West Germany, failed to explode only because of a flaw in its construction. Other attacks were averted thanks to Germany’s close cooperation with U.S. spy agencies, which provided tips and intelligence to their German colleagues. “That was a very important factor,” says Friedrich.

A poster released by the police shows the suspect of an attempted bomb attack at the central train station in Bonn, Germany, Dec. 13, 2012.
Ulrich Baumgarten—Getty Images

But Germany also acted early to counteract Islamist propaganda, dating back to before ISIS even emerged as a global terror network. Soon after the deadly shooting at Frankfurt airport in spring 2011, the government instituted a program that may seem counter-intuitive: it began making Islamic studies available to students of all ages, particularly around North-Rhine Westphalia, Germany’s most populous region and home to its largest Muslim communities.

Teachers in this region, whose capital is Düsseldorf, were given a “crash course” in the new Islamic curriculum, which was designed with the help of local imams and religious experts, says Ali Bas, a regional lawmaker who lobbied for this initiative and helps oversee its implementation.

As of this year, 17,000 students in the region were taking courses on Islam, a small fraction of the roughly 300,000 Muslim students in the region but double the number at the start of 2015. By next year, Bas expects the program to grow at an even faster pace, as the first group of teachers are due to complete their degrees in Islamic education and join the faculties of schools across the region.

One of their aims, says Bas, is to make young Muslims feel accepted, “to give them the feeling that they are important in our society.” The broader intention, he says, is to undermine the work of ISIS recruiters, who typically stoke feelings of alienation and social resentment. “Accepting this religion is, for us, a very important aspect of making younger people stronger against extremism,” says Bas, who is an ethnically Turkish Muslim.

The Signpost program, which Sauerborn established in 2014, takes a more targeted approach. With three offices around North-Rhine Westphalia, it offers parents and teachers a place to turn for advice when they see signs of radicalization among young men. In many cases, the program’s counselors go to the schools and hang-outs of devout Muslims in Düsseldorf and other cities to offer guidance, not only on questions of religion but also on social or financial issues, like finding a job or resolving a conflict with a teacher.

German converts to Islam are also invited to seek help from Signpost counselors, who often try to ensure that a convert does not become estranged from his family. “We’d call his mother and say, ‘Look, he’s just a Muslim,’” says Sauerborn. “’That’s not a crime. That’s his choice. That doesn’t mean he’s being radicalized.’”

The hardest part of the program’s mission is winning the trust of the Muslim community, especially among young men who might already feel persecuted or unjustly scrutinized by the authorities. The Federal Office for the Protection of the Constitution, Germany’s domestic intelligence service, pays the salaries of all of the program’s counselors, defines their responsibilities and oversees their work.

But the agency does not use them as informants, says Sauerborn, who sits on the executive board of the Düsseldorf police department. “There is no information exchange, and on that point the Federal Office is very consistent,” he says. “They have never asked for personal information about the people we work with. They just want us to be here to meet their needs.”

One of the program’s counselors agreed to talk to TIME, but only on the condition of anonymity so as not to alert other members of the Muslim community that he works for the German intelligence service. Over the past two years, he says he has worked with about 30 young men in Düsseldorf, some of whom had plans to travel to Syria and join ISIS.

“They think they need to go there and defend Islam, because of these propaganda videos and everything they’ve been told,” he says. In their attempts to dissuade such people, “we don’t say directly that [ISIS] is wrong, that it’s all lies. We have to speak with the people in such a way as to analyze the situation, to see what [Islamist] groups they are attached to, what they want to do in Syria. And then we try to provide concrete help.”

In one typical case the counselor handled earlier this year, a teacher called the Signpost hotline to report that a 13-year-old boy was showing clear signs of radicalization. The counselor then visited the his school several times to talk to him, not only about the tenets of Islam but about the boy’s feelings of animosity toward his German teachers and fellow students. “It turned out the boy felt discriminated against, as though nobody really understood him,” says the counselor. “All I did was make myself available, as a Muslim, to talk through these things.”

Bas, the local lawmaker, says this type of “role-model function” is the most useful social service the government can provide in trying to combat Islamic extremism. But it is no silver bullet. Over the past few years, about 800 Islamists have still left Germany to fight in Syria or Iraq, according to police statistics reported in local media.

Relative to its population, that is far lower than the number of ISIS fighters who have come from Germany’s neighbors. Some 1,800 have reportedly joined or tried to join ISIS from France, and another 450 have come from Belgium, whose Muslim community is about one-eighth the size of Germany’s. Neither France nor Belgium has yet created a program like Signpost, though Sauerborn wishes they would.

“It’s an important mission,” he told his young audience on the children’s television show. “We try to do everything possible to take them in a good direction, away from extremism.” The message seemed simple enough, even for the kids that Sauerborn and his colleagues in the police force see as their most important “clients.”

“If we can reach them early and develop some trust,” he told me after taping the show, “that’s the best chance we have to intervene.” It is a very narrow window of opportunity, and it would take far more resources than Signpost currently has to take full advantage of it. But with their hotline and their little office on the second floor of an apartment building, the police in Düsseldorf are at least trying to compete with ISIS on its ideological turf.

Contact us at editors@time.com.

SPONSORED FINANCIAL CONTENT

Read More From TIME

EDIT POST