Islam in Uttar Pradesh is the second largest religion in the state with 38,483,967 adherents in 2011, forming 19.26% of the total population. Muslims of Uttar Pradesh have also been referred to as Hindustani Musalman (). They do not form a unified ethnic community, but are differentiated by sectarian and Baradari divisions, as well as by language and geography. Nevertheless, the community shares some unifying cultural factors. Uttar Pradesh has more Muslims than any Muslim-majority country in the world except Indonesia, Pakistan, Bangladesh, Nigeria, Egypt, Iran and Turkey.
History
Early history
The earliest traces of Islam in Uttar Pradesh can be traced back to the early 11th century (1000-1030CE), when the religion was introduced to the region through various Ghurid and Ghaznavid attacks and incursions.
However, the first consolidated Muslim rule over much of Uttar Pradesh began after 1205 CE, when the region formed part of the various sultanates and was ruled from their capital, Delhi; as a result there arose a community in what is now Uttar Pradesh, referred to as Hindustani Musalmans. The term Hindustani Musalman was applied to Muslims who either converted to Islam or who had settled for a long time in India. They did not form a unified community as they were divided by ethnic, linguistic, and economic differences. When the Mongols rose to power under Genghis Khan, there was an influx of Muslim refugees into North India, many of whom settled in the provincial kasbahs and brought administrators from Iran; painters from China; theologians from Samarkand, Nishapur and Bukhara. In Azamgharh, Mubarakpur, Mau, and Vanaras, a number of cultural norms arose over time which typified many Uttar Pradesh Muslim traditions. The Turkic Sultans of Delhi and their Mughal successors patronized the émigré Muslim culture: Islamic jurists of the Sunni Hanafi school, Persian literati who were Shia Ithnā‘ashariyyah, and Sufis of several orders, including the Chishti, Qadiri and Naqshbandi.
Many Sufi missionaries from the Middle East and Central Asia migrated and settled in South Asia. Many natives converted to Islam due to the missionary Sufi saints whose dargahs populate South Asia. The Muslims from various Northern provinces such as Hyderabad Deccan, Balochistan, Sindh, Punjab, Gujarat, Kashmir and other parts of South Asia also moved to capitals of the Muslim empire in Delhi and Agra. Millions of natives converted to Islam during the Muslim rule. The Lodi dynasty was dominated by the Pashtuns soldiers from Khyber Pakhtunkhwa and Afghanistan who settled in northern India. After the First Battle of Panipat, Mughal Emperor Babur defeated the Lodi dynasty with Chagatai or Gurkani Türks, Uzbek, Turkmen and Uyghur soldiers and nobility. These soldiers and nobles were awarded estates and they settled with their families in northern India. These diverse ethnic, cultural, and linguistic groups merged with the Muslims of Uttar Pradesh over the centuries to form the Urdu speaking Muslim community of South Asia.
The Rohilla leader Daud Khan was awarded the Katehar (later called Rohilkhand) region in the then-northern India by Mughal emperor Aurangzeb Alamgir (ruled 1658–1707) to suppress the Rajput uprisings. Originally, some 20,000 soldiers from various Pashtun tribes (Yusafzai, Ghori, Osmani, Ghilzai, Barech, Marwat, Durrani, Tareen, Kakar, Naghar, Afridi and Khattak) were hired by Mughals to provide soldiers to the Mughal armies. Their performance was appreciated by Mughal emperor Aurangzeb Alamgir, and an additional force of 25,000 Pashtuns were recruited from modern Khyber Pakhtunkhwa and Afghanistan and were given respected positions in Mughal Army. Nearly all of Pashtuns settled in the Katehar region and also brought their families from modern Khyber Pakhtunkhwa and Afghanistan. During Nadir Shah's invasion of northern India in 1739, the new wave of Pashtuns settled increasing their population to over one 1 million. Due to the large settlement of Rohilla Afghans, the Katehar region became known as Rohilkhand. Bareilly was made the capital of the Rohilkhand state and it became a major Pashtun city with Gali Nawaban as the main royal street. Other important cities included Moradabad, Rampur, Shahjahanpur, and Badaun.