It is famous for its tropical islands and luxury resorts but in September the Maldives was shaken by an explosion which injured a dozen tourists.
The authorities called those responsible "Islamic extremists" influenced by foreign ideas of the religion and the country now faces the threat of being fractured along religious lines.
Abdullah Kamaludeen, the home affairs minister, told Al Jazeera: "If you look at our history, I think all our religious scholars went to the same schools.
"We were able to live our lives in a uniform way. It's only when the schools diversify that we have different schools of thoughts.
"That's what breeds terrorism and anti-social behaviour in people." Investigations into the September attack took the police to Himandhoo, a little island two hours west of the capital, Male, by fast boat.
What followed was a tense 40-hour standoff between members of the Dar-al-Khuir mosque and the authorities.
One of the masked members of the mosque said: "Until now we have not attacked anyone. But if the mosque is to be broken, they will have to break us first, because we love and respect the mosque."
And break them the authorities did as they moved in to shut down the mosque and arrest about 60 men and teenage boys.
More than 30 policemen were injured in the operation, including one whose hand was chopped off.
Mauroof Hussain, the vice-president of the opposition Adhalaath party, which is made up mostly of Islamic scholars, believes the social divide can be narrowed by introducing a stronger religious education system.
"Since there is no proper Islamic education here, there is a vacuum. People are really hungry for their religion, so they have to hunt it. Most go to the internet," he said.
"This causes them to adopt extreme views and … they become separate from mainstream society."
Mariya Didi of the Maldivian Democratic party said: "Faith is inside rather than out, so let's not judge everybody from what they’re seen and try to bring tolerance and teach that extremism doesn't produce results."
One result people want is a better life. Among the population of about 370,000 people, half are living in poverty.
Nearly 100,000 are packed into the capital, Male, an island that takes less than half an hour to walk across.
How the Maldives handles the differences over the application of an age-old religion in a fast-changing world will shape the country's social and political landscape.