Ansyaad Mbai, the head of Indonesia's National Counterterrorism Agency, in his office in Jakarta before a wall chart mapping out links between terrorist suspects and their networks since 1949, when Indonesia gained independence from the Netherlands. (Andrew Higgins/The Washington Post)

Every few months, the head of counterterrorism in the world’s most populous Muslim nation pays a visit to a Koranic academy south of the capital to address an assembly of clerics. His message, he says, is blunt: Stopping would-be bombers “is your job, not mine.”

Ansyaad Mbai’s plea for help is also surprising, given the string of successes against Islamist militants that Indonesian security services have notched in recent years. After a blaze of attacks inspired in part by al-Qaeda’s Sept. 11, 2001, strikes in the United States, the militants in Indonesia are now a battered and diminished force. In just over two years, 33 terrorism suspects have been killed, mostly in shootouts with police, and nearly 200 have been arrested.

The last significant attack in Jakarta, the capital, was in 2009. The rest of the country, too, has been spared anything like the 2002 bombings on the resort island of Bali that killed 202 people or the second Bali attack that killed 20 in 2005. No civilians have died in terrorist actions in the past 2½ years. The 13 fatalities in 2010 and 2011 — 10 in 2010 and three last year — have been police officers.

In a huge, ethnically diverse country that champions of global jihad once regarded as fertile ground for expansion, the recent calm testifies to the success of a relentless drive by security forces to track, infiltrate and confront violent Islamist groups intent on driving Indonesia from its traditionally moderate moorings.

The falling death toll, however, does not mean that terrorists are no longer active. An alleged plot to stage another attack in Bali fell apart in March when police killed five suspects as they gathered on the island to prepare for bombings at the Hard Rock Cafe and other Western-linked targets.

Mbai, the head of the National Counterterrorism Agency, said the continued plotting shows that authorities need to deploy more than just guns and handcuffs if they want to uproot, rather than just foil, terrorism.

And so, on four occasions over the past year, Mbai, a man reviled by radical Muslims in Indonesia as an enemy of the faith, has traveled here to Depok. He has spoken to a total of 500 clerics drawn from across the country for “anti-radicalization” sessions organized by Kulliyatul Quran al-Hikam, an Islamic boarding school.

“Only you have the capacity to compete, using Islam, with radicals,” Mbai said he told them.

‘Focus on fighting ideas’

Deploying Islam to fight violent, deviant offshoots is not a new idea. Saudi Arabia, sensitive to criticism that its own zealously puritanical strain of Islam, Wahhabism, promotes militancy, has had religion-based programs against radicalization for years. And, at the opposite end of the spectrum, Turkey and Malaysia have long kept a tight grip on what clerics can and cannot preach.

But Indonesia, torn between its attachment to relatively new democratic freedoms and its revulsion toward terrorism, has struggled for years to agree on ways to keep mosques, boarding schools and other institutions free of militant views.

“Counterterrorism is working, but there has been almost no progress on immunization against extremist teaching,” said Sidney Jones, a Jakarta-based expert on Southeast Asian terrorist networks with the International Crisis Group.

The government is trying to change that, drafting plans for a nationwide program to counter radical thinking, to be carried out by the counterterrorism agency, the Education Ministry and other government bodies.

“We have had a big success in fighting terrorism physically,” Mbai said, “but now we need to focus on fighting ideas.”

The view that Islam, or at least distorted versions of the faith, can contain the seeds of militancy does not sit well with many political and religious leaders.

“There is a huge resistance to anything that is seen as stigmatizing Islam,” Jones said.

A few miles from the Koranic school, Depok Mayor Nur Mahmudi Ismail returned to his city hall office after prayers on a recent evening and explained why police work and religion should not mix. Terrorism, he said, “is not due to religious teaching” and will stop only if “the government solves people’s problems.”

The problems that the mayor, a former chairman of the Islamist Prosperous Justice Party, or PKS, has sometimes focused on solving have raised eyebrows among secular-minded residents. He ordered that a billboard advertisement for deodorant on a busy street be taken down because it showed a woman’s armpit. As part of an effort to promote piety, he has been checking the registration certificates of karaoke parlors and says he will shut down those that do not comply with regulations.

Ismail denies wanting to force his own morality on residents and notes that he has come under fire from a hard-line group for not moving fast enough to shut down illegal drinking dens. The mayor recently received a package containing women’s lingerie and a hairpiece — a gesture of contempt for his alleged lack of manly toughness in enforcing Islamic norms.

The Ministry of Religious Affairs, a sprawling bureaucracy that doles out money to schools and other religious institutions, sees no link between faith and terrorism and is dead set against any trespassing on its turf by security officials. Police officers, said the religion minister, Suryadharma Ali, are welcome “to come to mosques to pray but not to control sermons” or anything else concerning faith.

His ministry, which is embroiled in a corruption scandal involving the procurement of overpriced Korans, publishes pamphlets promoting the “correct” nonviolent interpretation of jihad as a spiritual struggle for self-improvement and other Islamic concepts that have been hijacked by extremists.

But, unlike its equivalent in Malaysia, it does not review sermons or license preachers, something security chiefs would like to see. The religion minister said that, despite voluminous evidence of the role played by radical preachers in spreading violent ideas, “it is not clear why a small group of people do violence against others.”

Any effort to rein in wayward clerics, he said, would only backfire. Under President Suharto, Indonesia’s authoritarian ruler for more than three decades, “Islam was politically controlled,” Suryadharma said, and “the result was that radical views grew secretly and uncontrollably.”

The collapse of Suharto’s regime in 1998 led to an explosion of Islamist activism as organizations rushed to take advantage of new freedoms, whether they were political parties such as the PKS — now part of Indonesia’s coalition government — or thuggish vigilante groups such as the Islamic Defenders Front, or FPI.

The FPI regularly attacks bars and nightclubs, as well as Christian churches and the mosques of Ahmadiyah, a small sect it views as heretical. Denouncing Lady Gaga as a servant of Satan, the group this summer helped force the cancellation of a concert in Jakarta by the American performer. (It also sent the lingerie to the Depok mayor).

Islamist vigilante squads have almost no public support, and nonviolent Islamist political parties show no sign of building on early successes to challenge still-dominant secular parties. But the explosion of religion-tinged activism, said Mbai, has made it more difficult to confront head-on the ideas of radicals who claim to be acting for their faith.

Tackling radicalism at its source

To break through opposition to the idea that militant interpretations of Islam can spawn violence, the counterterrorism agency has turned for help to Nahdlatul Ulama, the world’s largest Islamic organization. The guardian of Indonesia’s traditionally moderate form of Islam, which has been influenced by centuries of contact with Hinduism, Buddhism and indigenous creeds, Nahdlatul Ulama controls a large network of boarding schools and mosques.

Haysim Muzadi, who headed the group for a decade, runs the Depok Koranic college that is collaborating with the National Counterterrorism Agency. Security forces, Muzadi said, “can only use repressive actions” against militancy and thus “need help from Islamic leaders” if they are to succeed.

He cites as a “good example” a decision this year by a Jakarta publishing house to withdraw and then burn copies of a book that had caused offense with remarks about the prophet Muhammad. The burning, Muzadi said, deprived radical hotheads of a cause and prevented any attacks on the publisher.

His school, which gets government cash for its efforts, has sought to tackle radical zeal at its source, working on a curriculum that draws a clean line between legitimate Islamic principles and what it sees as militant distortions. The library has banished works by Sayyid Qutb of Egypt and other radical theorists and is stacked instead with conservative Koranic commentaries and pamphlets by Indonesian writers denouncing imported strains of Islam.

Muzadi said he realized the danger posed by radical Islam during a 2002 visit to New York’s Ground Zero. “Everything became clear to me. I saw the threat. Radicals threaten not just America but the whole world. They also endanger Islam.”