The Karabakh Khanate ( — Khānāt-e Ḡarabāḡ, ) was a semi-independent Turkickhanate on the territories of modern Azerbaijan established in about 1750 under Persian suzerainty in Karabakh and adjacent areas. The Karabakh khanate existed until 1806, when the Russian Empire gained control over it from Persia. The Russian annexation of Karabakh was not formalized until the Treaty of Gulistan in 1813, when, as a result of Russo-Persian War (1804-1813), Fat′h Ali Shah Qajar of Persia officially ceded Karabakh to TsarAlexander I of Russia. The khanate was abolished in 1822, after a few years of Russian tolerance towards its Muslim rulers, and a province, with a military administration, was formed.