Safavid conquest of Shirvan

The conquest of Shirvan was the first campaign led by Ismail of the Safaviyya order. In late 1500, Ismail marched into Shirvan, and, despite heavily outnumbered, decisively defeated the then incumbent Shirvanshah Farrukh Yassar in a pitched battle, in which the latter and his entire army were killed. The conquest resulted in the toppling of the Shirvanshahs as autonomous rulers, who had ruled large parts of the Caucasus for centuries, the incorporation of their domain, and lead to the eventual proclamation of the Safavid state shortly after.

Background and war
Ismail's father Shaykh Haydar and his grandfather Shaykh Junayd had both been killed in battle by the rulers of Shirvan, in 1488 and 1460 respectively. In the summer of 1500, Ismail had rallied at Erzincan a force of 7,000 Qizilbash forces, consisting of the Ustaclu, Shamlu, Rumlu, Tekelu, Zhulkadir, Afshar, Qajar and Varsak tribes. Shortly before initiating his offensive, signalled by the weakness of the fragmented Georgian kingdoms, he looted Samtskhe. At the same time, he made the Georgian kings Constantine II and Alexander I of respectively the kingdoms of Kartli and Kakheti, to attack the Ottoman possessions near Tabriz, on the promise that he would cancel the tribute that Constantine was forced to pay to the Ak Koyunlu once Tabriz was captured. In December 1500, with the intention to avenge his murdered ancestors, Ismail crossed the Kura River into Shirvan with his 7,000-strong force, and decisively defeated and killed Farrukh Yassar, the then incumbent king of Shirvan and his entire 27,000-strong army in a pitched battle at Jabani, near the Shirvanshah capital of Shamakhi, or at Gulistan (present-day Gülüstan, Goranboy, Nagorno-Karabakh) and subsequently marched on to reach the Caspian coast, and took Baku.

Aftermath
By this victory, Ismail had toppled the Shirvanshahs, and successfully expanded his domains. After the conquest, Ismail had Alexander I of Kakheti send his son Demetre to Shirvan to negotiate a peace agreement. Ismail allowed the Shirvanshah family to remain in power in Shirvan for some more years, under Safavid suzerainty. In 1538, during the reign of Ismail's successor and son, Tahmasp I (r. 1524-1576), the Safavids completely removed the Shirvanshahs from power, and turned Shirvan into a fully functioning province governed by appointed officials.

The successful conquest had alarmed the ruler of the Aq Qoyunlu, Alvand, who subsequently proceeded north from Tabriz, and crossed the Aras River in order to challenge the Safavid forces, and a pitched battle was fought at Sarur in which Ismail's army came out victorious despite being outnumbered by four to one. After eventually conquering Tabriz and Nakhchivan, Ismail broke the promise he had made to Constantine, and made both the kingdoms of Kartli as well as Kakheti his vassals. In Tabriz, he proclaimed the Safavid dynasty and declared himself king (shah).