Since the founding of the empire, the Safavids had been Shi'ite Muslims and had made it the compulsory state religion. This decree meant that everyone had to be or convert to be a Shi'ite Muslim. Because the Safavids demanded everyone to convert, unlike the Ottoman and Mughul empires, there was much more tension and unrest within the empire. Shi'ite Muslims believed that the caliph, or religious ruler, had a direct relation to the family tree of Ali. The Sunni and Shi'ite Muslims fought many expensive wars because of these religious differences. Because of the influence of trade, the conversion to Shi'ite Muslim beliefs was no longer mandatory for visiting merchants from Europe. Yet, the presence of non-Muslim merchants did not improve the lack of tolerance for different religions in the Safavid