Shia Islam was brought to the Indian subcontinent during the final years of the Rashidun Caliphate. The Indian subcontinent also served as a refuge for some Shias escaping persecution from Umayyads, Abbasids, Ayyubids, and Ottomans. The immigration continued throughout the second millennium until the formation of modern nation states. Shi'ism also won converts among the local population.