Khankendi is located on the Gargar River, at the eastern foot of the Caucasus range, in 385 kilometers’ distance from Baku. Adminstratively, Khankendi combines one city (Khankendi) and  one settlement ( Karkijahan). It was the capital of Nagorno-Karabakh Autonomous Region. Its territory is 8.8 km², population is 55.9 thousand people (01.01.2020). The city of Khankendi was occupied by Armenian armed forces on December 28, 1991.

Khankendi borders on Kalbajar, Tartar, Aghdere, Aghdam in the north, Shusha in the south, Khojavend in  east, Lachin the west and in the centre it is surrounded by Khojali and Askeran regions.

Khankendi differs from other Azerbaijan cities being relatively young. According to the archive records, the city was founded at the ends of the XVIII century as a resting place of the Karabakh khans.  In order to create maximum condition for khans ‘activities, the city was settled at the foot of the mountain, in a 10- kilometers distance from Panahabad (now Shusha), the capital city of the Khanate. In the first years only khan’s family and relatives lived in the settlement, that’s why it was known as "Khanin kendi” (Khan’s village) among local people. After short time it was called Khankendi. However, Kankendi was founded for recreation purpose, from XX it started to develop as a new cultural and industrial centre of Azerbaijan. 

Enterprises constructed in Khankendi produced more than half of product of the oblast. Industrial output of the province was producing more than half of the enterprises built Khakendi. Silk, shoe, carpet, textile factories, dairy enterprise and winery operating in Khankendi were well-known in the South Caucasus. Electro-technology plant, furniture factory, construction materials factory occupied a worthy place in the domestic market.

When Nagorno-Karabakh Autonomous Region was established according to decree of the Central Executive Committee Soviets of Azerbaijan dated 07.07.1923, Khankendi was declared as the capital city of the region. In 18.09.1923 in accordance with the decision of the Karabakh Region Party Committee the name of the city was changed and renamed Stepanakert.

In accordance with Decree No.I X 837 of of the Presidium of the Supreme Sov’iet of Azerbaijan SSR dated 15.05.1978, the city center was moved from Stepanakert to workers settlement Askeran and  Stepanakert region was called Askeran..

In accordance with Decree No. 1783-XI of the Presidium of the Supreme Soviet of Azerbaijan SSR, dated 21.04.1990 Karkijahan residential area of the city of Stepanakert was attributed to the category of urban-type settlements and Kerkidzhahan.S Settlement Soviet was established within Stepanakert City Soviet. In accordnce with the Law of the  Azerbaijan Republic No. 279-XII "On the Liquidation of Nagorno Karabakh Autonomous Oblast of Azerbaijan" dated 26 November 1991, the historical name of the city Stepanakert was returned and  renamed Khankendi. 

As a result of the Second Karabakh War (27 September - 9 November 2020), Azerbaijani sovereignty was established over the city of Khankendi, and the territorial integrity of the Republic of Azerbaijan was restored. Karabakh is Azerbaijan!