After the death of Nader Afshar, the military commanders in the various provinces of Iran found local governments. In Khorasan, Shah Rukh who was the grandson of Nader and the last survivor of the Afsharid dynasty, Qajar tribe in Mazandaran and south of the country was under the command of Ali Mardan Khan Bakhtiari, where Karim Khan Zand was one of his brave commanders. Ali Mardan Khan first conquered Isfahan but later he was killed by one of his close companions, thus Karim Khan Zand took control in the south of the country and fought for fifteen years with the claimants of the monarchy and then establish the Zand dynasty.
He has chosen Shiraz as the capital and spent the last fifteen years of his reigning for the development of the city of Shiraz. The country flourished during its rule and trade ties between Iran and Britain were improved. The only foreign battle of the Zand Dynasty was the war with the Ottoman Empire, which led to the conquest of the port of Basra by Karim Khan Zand.
25 monuments were built during the era of the Zand Dynasty in Shiraz by Karim Khan Zand and the mosque and market of lawyers were among them. Because he was very fond of the people, he never called himself the king, he named himself the advocate of the people (Vakilol Ro’aya). Eventually, by the conquest of the Mohammad Khan Qajar, Zand Dynasty was extinct.