It is most commonly used as the title of a worship leader of a mosque and Muslim community among Sunni Muslims. In this context, imams may lead Islamic worship services, serve as community leaders, and provide religious guidance.
For Shi'a Muslims, the Imams are leaders of the Islamic community or ummah after the Prophet. The term is only applicable to the members of Ahl al-Bayt, the family of the Islamic Prophet Muhammad, considered infallibles by Twelver Shia. The title was also used by the Zaidi Shia Imams of Yemen, who eventually founded the Mutawakkilite Kingdom of Yemen (1918-1970).
The Sunni branch of Islam does not have imams in the same sense as the Shi'a, an important distinction often overlooked by those outside of the Islamic religion. In everyday terms, the imam for Sunni Muslims is the one who leads Islamic formal (Fard) prayers, even in locations besides the mosque, whenever prayers are done in a group of two or more with one person leading (imam) and the others following by copying his ritual actions of worship. Friday sermon is most often given by an appointed imam. All mosques have an imam to lead the (congregational) prayers, even though it may sometimes just be a member from the gathered congregation rather than an officially appointed salaried person. The position of women as imams is controversial. The person that should be chosen, according to Hadith, is one who has most knowledge of the Quran and Sunnah (prophetic tradition) and is of good character.
The term is also used for a recognized religious scholar or authority in Islam, often for the founding scholars of the four Sunni madhhabs, or schools of jurisprudence (fiqh). It may also refer to the Muslim scholars who created the analytical sciences related to Hadith or it may refer to the heads of Muhammad's family in their generational times.
Imams are appointed by the state to work at mosques and they are required to be graduates of an İmam Hatip high school or have a university degree in Theology. This is an official position regulated by the Presidency of Religious Affairs in Turkey and only males are appointed to this position while female officials under the same state organisation work as preachers and Qur'an course tutors, religious services experts. These officials are supposed to belong to the Hanafi school of the Sunni sect.
A central figure in an Islamic movement is also called an Imam, like the Imam Nabhawi in Syria.
In the Shi'a context, an imam is not only presented as the man of God par excellence, but as participating fully in the names, attributes, and acts that theology usually reserves for God alone. Imams have a meaning more central to belief, referring to leaders of the community. Twelver and Ismaili Shi'a believe that these imams are chosen by God to be perfect examples for the faithful and to lead all humanity in all aspects of life. They also believe that all the imams chosen are free from committing any sin, impeccability which is called ismah. These leaders must be followed since they are appointed by God.
In “The Epistle” (Risāla) by Khwāja Muḥammad Riḍā b. Sulṭān Ḥusayn, he writes that the Imam (Haḍrat-i Mawlānā) provides the miracle of knowledge (a trait exclusive to the Imam) only to the proof (ḥujjat), and the proof (ḥujjat) shares this miracle of knowledge with the community.
Fatimah, also Fatimah al-Zahraa, daughter of Muhammed (615–632), is also considered infallible but not an Imam. The Shi'a believe that the last Imam, the 12th Imam Mahdi will one day emerge on the Day of Resurrection (Qiyamah).
At times, have held both secular and religious authority. This was the case in Oman among the Kharijite or Ibadi sects. At times, the imams were elected. At other times the position was inherited, as with the Yaruba dynasty from 1624 and 1742. See List of rulers of Oman, the Rustamid dynasty: 776–909, Nabhani dynasty: 1154–1624, the Yaruba dynasty: 1624–1742, the Al Said: 1744–present for further information. The Imamate of Futa Jallon (1727-1896) was a Fulani state in West Africa where secular power alternated between two lines of hereditary Imams, or almami. In the Zaidi Shiite sect, imams were secular as well as spiritual leaders who held power in Yemen for more than a thousand years. In 897, a Zaidi ruler, al-Hadi ila'l-Haqq Yahya, founded a line of such imams, a theocratic form of government which survived until the second half of the 20th century. (See details under Zaidiyyah, History of Yemen, Imams of Yemen.)
Ruhollah Khomeini is officially referred to as Imam in Iran. Several Iranian places and institutions are named "Imam Khomeini", including a city, an international airport, a hospital, and a university.