Карабахское ханство
The Russian Empire consolidated its power in the Karabakh Khanate following the Treaty of Gulistan in 1813, when Iran was forced to recognize the belonging of the Karabakh Khanate, along most of the other khanates they possessed in the Caucasus, to Russia, comprising present-day Dagestan and most of the Azerbaijan Republic, while officially ceding Georgia as well, thus irrevocably losing the greater part of its Caucasian territories. Absolute consolidation of Russian power over Karabakh and the recently conquered parts of the Caucasus from Iran were confirmed with the outcome of the Russo-Persian War of 1826–1828 and the ensuing Treaty of Turkmenchay of 1828.