The crowning of Ismail as king of Iran in Tabriz in 1501 was low-key, as was his announcement that Shia Islam would henceforth be the official state religion. And yet this was a turning-point in Iranian history, with repercussions up to the present day.

Like most Iranians the Safavids (1501-1722) were Sunni, although like many outside Shi’ism they venerated Imam Ali (601-661), the first of the 12 Shia imams. The Sufi orders, sometimes based on trades or guilds, were the main way religion was organised, and they encouraged self-discipline, spirituality and mysticism in varying degrees.

Historians have differed on the nature of Iran’s ‘conversion’ under the Safavids: was Iran ripe in some way for Shiism? But they generally agree that the motivation of the new dynasty was political rather than religious.

Making Shi’ism the state religion served to distinguish Iranians from subjects of the rival Sunni-ruled Ottoman Empire. And importing what was largely a foreign creed restricted to centres in Bahrain, Iraq and Syria lessened the risk of any state religion exacerbating rivalries among Iranian tribes or the Safavids’ supporters.

In creating a new order the Safavids looked to Shia Islamic law and to the jurists (mujtahids) specialised in it. This suited their aim of giving Iran cohesion, rules and a strong state, but they also turned their backs on their own origins as Sufis and put in train tensions that have persisted for centuries. In Converting Persia, issued in paperback last year, Rula Abisaab, of McGill University, notes:

Even though distinguished jurists were in general revered and emulated, the clerical community as a whole, with its varying judicial ranks, were at times the center [sic] of ridicule and disdain among common Persians. Proponents of folk Sufism attracted a significant following along the lower classes, which perceived them as more genuine, altruistic, austere and generous than the jurists. These contradictory developments reflected a social protest against state support of the mujtahids, who manipulated the power to ‘discipline’ for self-interest and greed.

Iran today still shows a popular scepticism about mujtahids, or clerics, commonly called mullahs: think of Marmoulak (the Lizard), the 2004 film directed by Kamal Tabrizi, or indeed of everyday shared-taxi conversations. This long predates the Islamic Republic, and its roots may go back longer than clerical establishment instated by the Safavids.

Portrait of Shah Abbas, Iran, 17th century, who was the 5th Safavid Shah. The Safavids descended from Sheikh Safi, a Sufi who had died in 1334. Photograph: Alamy

In Islam without Allah?, published in 2000, Colin Turner, of Durham University, argued the Safavid dynasty in its haste to establish a strong state not only assigned priority to Islamic jurisprudence over all other branches of knowledge like philosophy or science, but thereby abstracted public adherence to rules from internal religious belief.

For Turner, this Safavid ‘externalism’ gave the Iranian state a deep-seated character that has persisted ever since:

The designation ‘internalist’ is intended to denote any Muslim writer or thinker whose scholarly attention was focused primarily on the fundamentals of belief (usul al-iman)…and dissemination of knowledge of God and His attributes (ma’rifa). In this sense, internalism has often been articulated best by those attached in some way or other to Sufism and Sufi orders…By contrast, the term ‘externalist’ is used to signify those Muslim scholars…whose primary consideration was the acquisition and promulgation of the ‘secondary sciences’ [including both jurisprudence and studying hadith, sayings of the prophet].

Turner traces the dichotomy back to the Quran, which he argues makes a distinction - oddly clearer in English because unlike Arabic it has capital letters - between ‘islam’ (small i), which is internal submission to God based on iman (belief), and Islam (capital I), the public submission to God’s laws. The faqih (jurist), who would become a cornerstone of the Safavid system, studies the interpretation and implementation of these rules, and does not necessarily seek to foster iman among the people.

But throughout Islamic history, writes Turner, some thinkers have emphasised the limited nature of jurisprudence and its practitioners, the fuqaha (plural of faqih). Among these was Abu Hamad Muhammad al-Ghazali, the Tus-born 12-century philosopher who tried to balance different aspects of Islam.

According to Ghazali, writes Turner, jurisprudence is connected with religion only indirectly…The regulation of social life and form of government are secondary – albeit indispensable – adjuncts to the fundamentals of belief, and it is the regulation of social life and government, with its myriad rules and laws, that form the domain of the jurist. The heart is removed from this domain, since attention is focused only on the outward confession (Islam) and not the inward intention.

Turner illustrates Ghazali’s jaundiced view of many jurists in a quote that they disdained other disciplines like medicine because they did not involve “the management of religious endowments (awqaf), execution of wills, possession of the money of orphans, and appointment to judicial and government positions through which one exalts himself above his fellow men and fastens his yoke on his enemies”.

A couple lies in the Naqsh-e Jahan Square in Isfahan, surrounded by buildings from the Safavid era. Photograph: John Moore/Getty Images

Initially, the Safavids brought clerics from the Arab world, particularly Jabal Amil in what is now south Lebanon, but gradually a new breed of Iranian Shia faqih emerged. Of these, Mohammad Baqir Majlisi, appointed to the state-sponsored posts of Friday prayer leader in the Safavid capital Isfahan in 1660s and shaykh al-Islam in 1687, was particularly important.

According to Turner, “it was under Majlisi that Twelver Shi’ite externalism became truly orthodox, while all other views were rejected and often forcibly repressed”:

One of Majlisi’s first acts was to destroy the idols of a Hindu temple that had been set up by Indian merchants in the capital…the heartbroken Hindu keeper of the temple consequently committed suicide…Majlisi also obtained a decree for the expulsion of Sufis from the capital, which was rigidly enforced …Majlisi wrote several decrees on the correct way of performing the canonical prayer (salat), on the treatment of zakat [alms-giving] and on the rules of fasting. Such works of jurisprudence were the stock-in-trade of the externalists.

Majlisi wrote mainly in Persian rather than Arabic, giving his works a wider audience. In these he didn’t just clarify issues of prayer and alms giving, he strongly condemned Sufi practices like singing, dancing, vegetarianism and seclusion.

The question raised by works such as Turner and Abisaab is where popular, internal religiosity went. For Turner, identification with the 12 Shia Imams was encouraged to fill the gap:

Conveying simple, uncluttered dogma in the language of the common people – whom he was said to despise – he [Majlisi] was able to…fill the spiritual vacuum that had appeared as a result of the decline of Sufi brotherhoods with treatise after treatise on the lives, sayings, trials, tribulations, miracles and powers of the Imams…Twelver Shi’ism under the auspices of Majlisi became truly orthodox, and all other views were rejected and often forcibly repressed. True to his externalist ideals, Majlisi preached that iman was incomplete without belief in the Imam …

Even before Majlisi, who lived in the latter part of the Safavid dynasty before its overthrow by Afghan invaders in 1722, the Safavids fostered the mourning rituals of Ashura, in which believers were encouraged to invest deep personal feelings in re-enacting the 680 Battle of Kerbala when Imam Hossein was killed. The state also encouraged the development of imamzadehs, shrines to the relatives of the Imams. The shrines, especially the most frequented in Mashhad and Qom, channelled religious belief in a direction well-guarded by the clerics.

But not completely. There often has been those challenging officialdom and its rulings. Many Iranians, including Mohammad Shah (1834-48), were attracted by Sufism in one form or another, and in the 19th century Mirza Husayn-Ali Nuri – known as Bahaullah - gained many followers for the mysticism of what became the Bahai sect, which today claims 5 million adherents worldwide but has faced consistent persecution in Iran.

The clerics still show nervousness over popular spiritualism, even when it is related to the 12 Imams. In his 2005 presidential election campaign Mahmoud Ahmadinejad played off religious practices evoking age-old piety and mysticism. He “rode a wave using mosque-based organisations and even maddahs (religious singers) to gain support,” as Mohammad-Ali Abtahi, the former reformist vice-president, once put it.

But the most successful figure in linking Shia jurisprudence to popular religiosity has surely been Ayatollah Ruhollah Khomeini. In a 1993 essay, Said Amir Arjomand noted, “Khomeini’s interest in theosophy (erfan) made him a very atypical Shi’ite jurist”.

Khomeini’s lifelong interest in erfan – ‘intimacy with God’ – reflected a personal mysticism that fuelled his interest in Ibn Arabi (1165-1240) and Mullah Sadra (1571-1640) as well as the poets Rumi and Hafez. These are among the figures Safavid ‘externalism’ had tried to break from, and they remained out of favour among clerics in the twentieth century to the extent that Khomeini as a young man rising through the religious ranks was discrete over his interest.

For Turner, Mulla Sadra was a “notable example” of an ‘internalist’ with a focus on “the fundamentals of belief (usul al-iman)”. But despite Khomeini’s interest in iman, Turner argues that neither he nor Ali Shariati, the sociologist who shaped Iranian revolutionaries’ thinking in the years up to the 1979 Revolution, really broke with Safavid externalism.

…In Safavid Shi’ism, says Shariati, intizar[waiting for the return of the hidden Imam] entails spiritual and practical submission to the status quo…Shariati was able to identify the problems of externalism yet, instead of advocating a return to fundamentals in the manner adumbrated by Ghazali and Mulla Sadra, set about prescribing a whole new set of values which, although appearing to be totally divorced from what he calls the stagnation of Safavid Shi’ite externalism, in practice amount to little more than a variation on the same theme …

Reaction against the political quietism of Majlisi and his fellow fuqaha can be seen as a major factor in the acquisitions by twentieth-century Twelver Shi’ism of a new and revolutionary face…a Shi’ism that, by stressing politics rather than fiqh [jurisprudence], and revolution rather than weeping over the death of Husayn, continues, deliberately or unwittingly as the case may be, to champion the externalism discourse and obfuscate the eternal truths and realities of iman.

The seeds had been sown by the Safavids. In her 2002 Mystics, Monarchs and Messiahs, which sought to highlight the rich diversity and intense religiosity the Safavids lost, Kathryn Babayan wrote:

…with the Safavid patronage of Shi’i scholars, judges and preachers, the foundations of a religious establishment were actualized (sic) … These Shi’i scholars challenged charismatic mystics…in the absence of the hidden Imam, these specialists not only claimed direct access to God; some…would argue that political rule was reserved for them as well. With the Islamic Republic in Iran in 1979, the mujtahid would eclipse the figure of the monarch.

Iranian émigré Kader Abdolah read the Qur’an for the first time after 9/11 and was moved to write his own version – which involved reordering, cutting and even adding a chapter. So what is lost and what is gained?