Iran is an Islamic state. The Islamic conquest of Persia (637-651) led to the end of the Sassanid Empire and the eventual decline of the Zoroastrian religion in Persia. However, the achievements of the previous Persian civilizations were not lost, but were to a great extent absorbed by the new Islamic polity. Islam has been the official religion of Iran since then, except short duration after Mongol raid and establishment of Ilkhanate. Iran became an Islamic republic after the Islamic Revolution of 1979
Before the Islamic conquest, the Persians had been mainly Zoroastrian, however, there were also large and thriving Christian and Jewish communities. Eastern Iran (what is now Afghanistan) was predominantly Buddhist. There was a slow but steady movement of the population toward Islam. When Islam was introduced to Iranians, the nobility and city-dwellers were the first to convert, Islam spread more slowly among the peasantry and the dihqans, or landed gentry. By the late 11th century, the majority of Persians had become Muslim, at least nominally.
Though Iran is known today as a stronghold of the Shi'a Muslim faith, it did not become so until much later, around the 15th century. The Safavid dynasty made Shi'a Islam the official state religion in the early sixteenth century and aggressively proselytized on its behalf. It is also believed that by the mid-seventeenth century most people in Iran had become Shi'as, an affiliation that has continued. Over the following centuries, with the state-fostered rise of a Persian-based Shi'ite clergy, a synthesis was formed between Persian culture and Shi'ite Islam that marked each indelibly with the tincture of the other.
Nowadays Islam is the religion of 98% of Iranians, approximately 90% of Iranians are Shi'a and 8% are Sunni, mostly Turkomen, a minority of Arabs (mainly in Hormozgan Province), Baluchs, and Kurds living in the south, southeast, northeast and northwest. Almost all of Iranian Shi'as are Twelvers.