Borders of Time

Asia and the Middle East

The history of Azerbaijan

The whole story, from the first peoples to today, with every state that has held Baku on our historical maps.

Key dates (16)
  1. c. 10000 BCEHunter-gatherers begin carving the rock art of Gobustan, near Baku.
  2. 252 CEThe Sasanian Empire makes Caucasian Albania a vassal kingdom.
  3. 667 CEThe Albanian prince Javanshir submits to the Arab caliphate.
  4. 861 CEThe Shirvanshah dynasty begins nearly seven centuries of rule in Shirvan.
  5. 1139An earthquake destroys Ganja, home of the poet Nizami Ganjavi.
  6. 1501Ismail I, crowned at Tabriz, founds the Safavid state, which makes Shia Islam its religion.
  7. 1828The Treaty of Turkmenchay completes the division of Azerbaijani lands between Russia and Persia along the Aras river.
  8. 1872Baku's oilfields are opened to private enterprise, launching an oil boom.
  9. 1918The Azerbaijan Democratic Republic declares independence on 28 May.
  10. 1920The Red Army invades and Azerbaijan becomes a Soviet republic.
  11. 1990Soviet troops kill more than 130 people in Baku on Black January.
  12. 1991Azerbaijan declares its independence from the Soviet Union on 30 August.
  13. 1994A ceasefire ends the First Nagorno-Karabakh War, and the oil "contract of the century" is signed.
  14. 2020Azerbaijan recaptures most of the territories lost in the 1990s in a 44-day war.
  15. 2023A one-day offensive brings all of Nagorno-Karabakh under Azerbaijani control.
  16. 2025Azerbaijan and Armenia initial a peace treaty at the White House.
Hear the whole article read aloud

Azerbaijan lies on the western shore of the Caspian Sea, between the Greater Caucasus mountains and the Iranian plateau. In antiquity its lands formed the kingdom of Caucasian Albania, a Christian realm under Parthian and Sasanian Persian influence, and after the Arab conquests they became part of the Islamic world. From the eleventh century Oghuz Turkic settlement gave the region its Turkic language, while Persian culture, Shia Islam under the Safavids and local dynasties such as the Shirvanshahs shaped its identity. Divided between Russia and Persia in the early nineteenth century, the northern part became an oil frontier around Baku, a short-lived democratic republic in 1918 and a Soviet republic from 1920. Independent since 1991, Azerbaijan lost Nagorno-Karabakh and surrounding districts in a war with Armenian forces in the 1990s, and recaptured them in 2020 and 2023.

Prehistory

The Azykh cave, in the south of the Karabakh mountains, holds traces of human habitation hundreds of thousands of years old, and a jawbone of an early human found there in 1968 is among the oldest human remains from the former Soviet Union. On the rocky hills of Gobustan, south of Baku, hunter-gatherers carved thousands of petroglyphs from around the end of the last Ice Age onwards, showing hunters, dancers, animals and reed boats. Farming villages of the Shulaveri–Shomu culture appeared in the west in the sixth millennium BCE, and in the fourth and third millennia BCE the Kura–Araxes culture, named after the region's two great rivers, spread across the Caucasus. Copper and later bronze working flourished in the mountains, and Iron Age burial mounds dot the Talysh hills and Nakhchivan.

Medes, Persians and Greeks

In the first millennium BCE the lands south of the Aras river came under the Medes and then the Achaemenid Empire of Cyrus the Great. After Alexander the Great's conquest, a Persian general named Atropates founded a kingdom south of the Aras, Atropatene, from which the name Azerbaijan derives. The name was used for centuries for the region now in north-western Iran; it was applied to the lands north of the Aras only in 1918. Zoroastrianism took deep root, encouraged by the natural gas fires that burn on the Absheron peninsula, and the region later became famous for its fire temples.

Caucasian Albania

North of the Aras, the tribes of the eastern Caucasus formed the kingdom of Caucasian Albania by the first century BCE, unrelated to Albania in the Balkans. Its capital was at Kabala and later Partav (modern Barda). Roman legions under Pompey campaigned here in 65 BCE, and an inscription of the Twelfth Legion near Gobustan, from the reign of Domitian, is the easternmost Latin inscription known. The kingdom was more often in the orbit of the Parthian Empire and its Arsacid rulers. Armenian kingdoms held the lands of Artsakh and Utik south of the Kura river from the second century BCE, and the history of these territories, and of their peoples, is now contested between Armenian and Azerbaijani historians.

The Sasanian Empire made Albania a vassal state in 252–253. Its kings accepted Christianity in the fourth century, under the influence of the Armenian Church, and the Albanian Church developed its own alphabet. The Sasanians built the great walls of Derbent, just north of modern Azerbaijan, to keep steppe nomads such as the Huns and later the Khazars out of the region. In the seventh century the Mihranid princes, ruling from Partav, governed the kingdom; the most famous of them, Javanshir, fought alongside the Persians against the Arabs before switching allegiance.

Arab rule and local dynasties

Arab armies of the caliphate reached the Caucasus in the 640s, and Javanshir submitted to the caliph in 667. Under the Umayyad and Abbasid caliphates the region, called Arran by Arab geographers, became a frontier province in the wars against the Khazars. Islam gradually spread, and much of the Albanian Christian population was absorbed by Muslims or by the Armenian Church. In the ninth century the Khurramite rebel Babak, based in the mountains south of the Aras, defied the caliphs for twenty years before his capture and execution in 838.

As Abbasid power weakened, local dynasties took control: the Sajids, the Sallarids, the Kurdish Shaddadids of Ganja, and above all the Shirvanshahs. Of Arab origin but increasingly Persian in culture, the Shirvanshahs ruled Shirvan, the north-eastern lowlands, from 861 until the Safavid conquest of 1538, one of the longest-lived dynasties in the Islamic world, and built the Palace of the Shirvanshahs in Baku in the fifteenth century. Rus raiders sailed down the Volga and sacked Barda in 943–944.

Seljuks, Atabegs and Mongols

In the eleventh century Oghuz Turkic tribes migrated into the region, and the Seljuk Empire conquered it in the 1060s and 1070s. Turkic settlement over the following centuries gradually made a Turkic language, the ancestor of modern Azerbaijani, the main tongue of the population. In the twelfth century the Eldiguzid atabegs, nominally Seljuk governors, ruled a powerful state from Nakhchivan and then Tabriz, competing with the kingdom of Georgia. This was a great age of Persian literature: Nizami Ganjavi of Ganja wrote his five long romantic poems, the Khamsa, and his contemporaries included the poets Khaqani and Mahsati. The earthquake that destroyed Ganja in 1139 is among the deadliest in history.

The Mongol invasions began in 1220, and from 1256 the region was part of the Ilkhanate, whose capitals at Maragha and Tabriz lay just to the south. Its northern lands were repeatedly fought over with the Golden Horde. Tamerlane invaded in the 1380s, and in the fifteenth century the Turkmen confederations of the Kara Koyunlu and then the Aq Qoyunlu ruled from Tabriz.

The Safavids and the khanates

In 1501 Ismail, the young leader of the Safavid Sufi order, whose followers were Turkic-speaking tribesmen, was crowned shah at Tabriz. The Safavid Empire made Twelver Shia Islam the state religion of Iran, and over the following century most of the population of Azerbaijan became Shia. Ismail himself wrote poetry in Azerbaijani Turkic. Shirvan was annexed in 1538. The region was a battlefield in the long Safavid wars with the Ottoman Empire, which occupied it from 1578 to 1603 and again in the 1720s, when Peter the Great also seized Baku and the Caspian coast for a time.

After the death of Nader Shah in 1747, the region broke up into semi-independent khanates, among them Karabakh, Shirvan, Sheki, Ganja, Baku, Quba, Nakhchivan and Erivan, each ruled by a local dynasty under loose Persian overlordship. The Karabakh khans built the fortress town of Shusha in the 1750s.

Russian conquest and the oil boom

The Russian Empire, expanding into the Caucasus, took the khanates one by one, storming Ganja in 1804. Two Russo-Persian wars ended with the treaties of Gulistan in 1813 and Turkmenchay in 1828, which fixed the border on the Aras river. The Azerbaijani-speaking population was split between the Russian north and the larger Persian south, a division that endures today between the Republic of Azerbaijan and the provinces of north-western Iran. Russia also resettled Armenians from Persia and the Ottoman lands in the region.

Oil had been dug from pits on the Absheron peninsula for centuries, but when Russia opened the fields to private enterprise in 1872, Baku became one of the world's great oil towns. The Nobel brothers, the Rothschilds and local Azerbaijani millionaires such as Zeynalabdin Taghiyev built wells, refineries, pipelines and the first oil tankers, and around 1900 Baku produced about half of the world's oil. A new Azerbaijani intelligentsia emerged, publishing newspapers and staging the first opera in the Muslim world, Uzeyir Hajibeyov's Leyli and Majnun, in 1908. Tensions between Muslims and Armenians, who formed much of Baku's commercial class, erupted in deadly clashes in 1905–1906.

The Azerbaijan Democratic Republic

After the Russian Revolution, Baku was held by a Bolshevik-led commune. In March 1918 fighting there turned into the March Days, in which Bolshevik and Armenian Dashnak forces killed thousands of Muslims. On 28 May 1918 the Musavat party in Ganja proclaimed the Azerbaijan Democratic Republic, often described as the first parliamentary democracy in the Muslim world; it gave women the vote in 1919. In September an Ottoman-Azerbaijani army took Baku, followed by the killing of thousands of Armenians. The republic fought Armenia over Karabakh, Zangezur and Nakhchivan, and on 28 April 1920 the Red Army invaded, ending its independence.

Soviet Azerbaijan

The Azerbaijan Soviet Socialist Republic joined the Transcaucasian federation in 1922 and became a separate Soviet republic in 1936. In 1921 Moscow placed Nagorno-Karabakh, with its Armenian majority, in Soviet Azerbaijan as an autonomous region, and the Treaty of Kars made Nakhchivan an autonomous republic of Azerbaijan. Collectivisation and Joseph Stalin's purges killed many writers, officials and religious leaders, and the Latin alphabet introduced in the 1920s was replaced by Cyrillic in 1939. Baku's oil was vital to the Soviet war effort in World War II, and seizing it was a key aim of the German offensive into the Caucasus in 1942, which never reached Azerbaijan. Soviet troops occupied north-western Iran during the war and sponsored a short-lived Azerbaijani autonomous government in Tabriz in 1945–1946.

Heydar Aliyev, a KGB officer, led the republic's Communist Party from 1969 to 1982 and then joined the Politburo in Moscow. In the late 1980s, under Mikhail Gorbachev, the movement in Nagorno-Karabakh to join Soviet Armenia, and violence between Armenians and Azerbaijanis, including a pogrom against Armenians in Sumgait in February 1988 and the expulsion of Azerbaijanis from Armenia, set off a national movement led by the Popular Front. After anti-Armenian violence in Baku in January 1990, Soviet troops stormed the city on 20 January, killing more than 130 civilians; Black January is remembered as a turning point toward independence.

Independence and the first Karabakh war

Azerbaijan declared independence on 30 August 1991, confirmed by referendum that December as the Soviet Union dissolved. The Armenians of Nagorno-Karabakh declared their own republic, and full-scale war followed in 1992. Both sides committed atrocities. In February 1992 Armenian forces killed hundreds of Azerbaijani civilians fleeing the town of Khojaly, the worst massacre of the war, and Azerbaijani forces killed Armenian civilians at Maraga in April. Political turmoil in Baku saw President Ayaz Mutallibov resign and the Popular Front leader Abulfaz Elchibey elected in 1992, only to be driven out by a military revolt in 1993, which brought Heydar Aliyev back to power.

By the ceasefire of May 1994, Armenian forces held almost all of Nagorno-Karabakh and all or part of seven surrounding districts, together about 14 percent of Azerbaijan's internationally recognised territory by independent estimates, though Azerbaijan often cited a fifth. About 30,000 people had died. An estimated 500,000 Azerbaijanis had been displaced from Armenia, Karabakh and the occupied districts, and about 350,000 Armenians had left Azerbaijan. The UN Security Council called for the withdrawal of occupying forces in 1993, and mediation by the OSCE Minsk Group, chaired by Russia, France and the United States, produced no settlement.

The Aliyev era and oil wealth

In September 1994 Heydar Aliyev signed the "contract of the century" with a BP-led consortium to develop the offshore Azeri–Chirag–Gunashli fields. The Baku–Tbilisi–Ceyhan pipeline, opened in 2005, carried Caspian oil to the Mediterranean through Georgia and Turkey, and later gas pipelines linked the Shah Deniz field to Europe. Oil wealth transformed Baku with new towers and boulevards and paid for a growing army. Close ties with Turkey, summed up in the phrase "one nation, two states", became the core of foreign policy, alongside balanced relations with Russia, Israel and the West.

When Heydar Aliyev died in 2003, his son Ilham succeeded him as president. Presidential term limits were abolished by referendum in 2009, and in 2017 his wife Mehriban became first vice-president. Elections have been judged neither free nor fair by international observers, and opposition activists and journalists have been imprisoned in large numbers. Fighting along the Karabakh front flared repeatedly, most seriously in April 2016.

The wars of 2020 and 2023

On 27 September 2020 Azerbaijan launched an offensive, supported by Turkey and using Turkish and Israeli drones. In 44 days it recaptured the seven surrounding districts and about a third of Nagorno-Karabakh, including Shusha, which Azerbaijanis regard as their cultural capital. A Russian-brokered ceasefire on 10 November left the rest of the region under Armenian control with Russian peacekeepers guarding the Lachin corridor to Armenia. Some 3,000 Azerbaijani and 4,000 Armenian soldiers were killed. The victory was celebrated in Azerbaijan, where the government began rebuilding towns in the recovered lands, ruined since the 1990s, and resettling former residents.

From December 2022 the Lachin corridor was blocked, first by Azerbaijanis described by the government as environmental protesters and from April 2023 by an Azerbaijani checkpoint, and the Armenian population of Karabakh, about 120,000 people, suffered shortages of food, fuel and medicine. On 19 September 2023 Azerbaijan launched a military offensive, and the Karabakh authorities agreed to disarm the next day. More than 100,000 Armenians, almost the entire population, then left for Armenia. Azerbaijan described the operation as the restoration of its sovereignty over its own territory and said the residents had left of their own choice after being offered integration as citizens; Armenia, the European Parliament and many human rights groups and genocide scholars described the blockade and exodus as ethnic cleansing. The self-declared Republic of Artsakh announced its dissolution from 1 January 2024, and Russian peacekeepers left in 2024. Several former Karabakh Armenian leaders were later put on trial in Baku.

Azerbaijan since 2023

Ilham Aliyev called an early presidential election in February 2024, which he won with more than 92 percent of the vote after the main opposition parties boycotted it. Baku hosted the United Nations climate conference, COP29, in November 2024. Peace talks with Armenia produced an agreed treaty text in March 2025, and on 8 August 2025, at the White House, Aliyev and Armenian Prime Minister Nikol Pashinyan initialled the treaty and signed a joint declaration brokered by US President Donald Trump. It provided for a transit route across Armenia's Syunik province linking mainland Azerbaijan to its Nakhchivan exclave, long sought by Baku, to be developed with US involvement as the Trump Route for International Peace and Prosperity. Azerbaijan has said it will sign the treaty only after Armenia removes from its constitution a reference to Karabakh's unification with Armenia. Supporters of the deal saw the end of a conflict of nearly four decades; critics pointed to the unresolved fate of the displaced Karabakh Armenians and of Armenians detained in Azerbaijan.

Who held Baku?

25 periods

The state drawn at the site of today’s capital on each of our maps. Open any year to see the borders of the time.

  1. 2000 BCE – 1500 BCECatacomb cultureMap of 2000 BCE →
  2. 1500 BCE – 500 BCECimeriansMap of 1500 BCE →
  3. 500 BCE – 200 BCENo state drawn here on the mapMap of 500 BCE →
  4. 200 BCE – 100 BCEScythiansMap of 200 BCE →
  5. 100 BCE – 1 BCESarmatesMap of 100 BCE →
  6. 1 BCE – 100 CENo state drawn here on the mapMap of 1 BCE →
  7. 100 CE – 200 CEAlansMap of 100 CE →
  8. 200 CE – 500 CENo state drawn here on the mapMap of 200 CE →
  9. 500 CE – 700 CESasanian EmpireMap of 500 CE →
  10. 700 CE – 800 CECaucasian AlbaniaMap of 700 CE →
  11. 800 CE – 1000 CEAbbasid CaliphateMap of 800 CE →
  12. 1000 CE – 1200 CEShirvanMap of 1000 CE →
  13. 1200 CE – 1279 CEEldiguzids and ShirvanMap of 1200 CE →
  14. 1279 CE – 1300 CEIlkhanateunder Mongol EmpireMap of 1279 CE →
  15. 1300 CE – 1400 CEIlkhanateMap of 1300 CE →
  16. 1400 CE – 1492 CETimurid EmpireMap of 1400 CE →
  17. 1492 CE – 1530 CEEmirate of the White Sheep TurksMap of 1492 CE →
  18. 1530 CE – 1715 CEOttoman EmpireMap of 1530 CE →
  19. 1715 CE – 1783 CESafavid EmpireMap of 1715 CE →
  20. 1783 CE – 1815 CECaucasian khanatesMap of 1783 CE →
  21. 1815 CE – 1914 CERussian EmpireMap of 1815 CE →
  22. 1914 CE – 1920 CEAzerbaijanMap of 1914 CE →
  23. 1920 CE – 1930 CEAzerbaijanunder USSRMap of 1920 CE →
  24. 1930 CE – 1994 CEUSSRMap of 1930 CE →
  25. 1994 CE – todayAzerbaijanMap of 1994 CE →

Empires and states on this land

11

Every state in the atlas whose territory, at its height, reached into today’s Azerbaijan.

Visit today

See Azerbaijan for yourself

Guided tours, museum and monument tickets, and day trips across Azerbaijan, from the capital to the historic sites.

Tours and tickets in Azerbaijan

On GetYourGuide. We may earn a commission if you book. See our disclosure.

Azerbaijan elsewhere on the site

Other countries
Armenia, Georgia, Iran, Turkmenistan

Who ruled its cities?