Ottoman–Safavid War (1623–1639)

The Ottoman–Safavid War of 1623–1639 was a conflict fought between the Ottoman Empire and Safavid Iran, then the two major powers of Western Asia, over control of Mesopotamia. After initial Persian success in recapturing Baghdad and most of modern Iraq, having lost it for 90 years, the war became a stalemate as the Persians were unable to press further into the Ottoman Empire, and the Ottomans themselves were distracted by wars in Europe and weakened by internal turmoil. Eventually, the Ottomans were able to recover Baghdad, taking heavy losses in the final siege, and the signing of the Treaty of Zuhab ended the war in an Ottoman victory. Roughly speaking, the treaty restored the borders of 1555, with the Safavids keeping Daghestan, Shirvan, eastern Georgia, and Eastern Armenia, while western Georgia and Western Armenia decisively came under Ottoman rule. The eastern part of Samtskhe (Meskheti) was irrevocably lost to the Ottomans as well as Mesopotamia. Although parts of Mesopotamia were briefly retaken by the Iranians later on in history, notably during the reigns of Nader Shah (1736–1747) and Karim Khan Zand (1751–1779), it remained thenceforth in Ottoman hands until the aftermath of World War I.

Background
Starting in 1514, for over a century the Ottoman Empire and Safavid Iran were engaged in almost constant warfare over control of the South Caucasus and Mesopotamia. The two states were the greatest powers of West Asia, and the rivalry was further fueled by dogmatic differences: the Ottomans were Sunnis, while the Safavids were staunch Shia Muslims, who were seen as heretics by the Ottomans.

After the Battle of Chaldiran eliminated Safavid influence in Anatolia, during the war of 1532–55 the Ottomans conquered Arab Iraq, taking Baghdad in 1534 and securing recognition of their gains by the Treaty of Amasya in 1555. Peace lasted for two decades before another war began in 1578. The Persians were hard pressed, as the Ottoman advances were combined with an attack by the Shaybanids into Persian Khorasan. The war ended with the Treaty of Constantinople in 1590, with a clear Ottoman victory: the Ottomans occupied Georgia, Revan, and even the former Safavid capital, Tabriz.

The new Persian Shah, Abbas the Great (reigned 1588–1629), reorganized his army, raising the new gholam infantry in imitation of the Janissaries, conscripted from tens of thousands of mostly Circassians and Georgians armed with the best equipment and training, and bided his time. In 1603, he launched an offensive that retook Tabriz, Azerbaijan and Georgia in the same year. The Ottomans, distracted by wars with the Habsburg monarchy in Europe, failed to offer effective resistance. By 1622, following a successful conclusion of the war against the Mughals, and encouraged by the internal turmoil within the Ottoman Empire that followed the murder of Sultan Osman II (r. 1618–22), Abbas resolved to attack the Ottoman possessions in Iraq.

The war
The Shah's opportunity came with a series of rebellions in the Ottoman Empire: Abaza Mehmed Pasha, the governor of Erzurum, rose in rebellion, while Baghdad had been since 1621 in the hands of an officer of the Janissaries, the subashi Bakr, and his followers. Bakr had sought his recognition as the local pasha from the Porte, but the Sultan had ordered Hafız Ahmed Pasha, the governor of Diyarbakir, to intervene. Bakr then turned to Abbas, who sent troops to Bakr's aid. To forestall a Persian capture of Baghdad, Hafız Ahmed quickly restored relations with Bakr, who returned to Ottoman allegiance. In response, the Persians besieged Baghdad and took it on 14 January 1624, with the aid of Bakr's son, Muhammad. The fall of the city was followed by the massacre of a large part of its Sunni inhabitants, as the Shah endeavored to transform Baghdad into a purely Shiite city.

The fall of Baghdad was a major blow to Ottoman prestige. Ottoman garrisons and the local tribes began to defect, and the Persians soon captured most of Iraq, including the cities of Kirkuk and Mosul and the Shia holy shrines of Najaf and Karbala, which the Shah visited. In 1625, Hafız Ahmed Pasha, now Grand Vizier, marched to retake Baghdad. Despite a "scorched earth" policy ordered by the Shah, the Ottoman army reached Baghdad and invested it in November on three sides. The Ottoman assaults on the city managed to penetrate the outer fortifications, but failed to take the city before the arrival of a relief army under Shah Abbas. The Ottomans then withdrew within their strongly fortified camp, and continued to prosecute the siege. In response, Abbas decided to intercept Ottoman supply convoys. This strategy bore fruit: the Ottomans were forced to risk an attack on the Persian army, which was repulsed with heavy losses, and on 4 July 1626, the Ottoman army lifted the siege and withdrew to Mosul.



In 1629, the Ottomans, having secured peace with the Habsburgs, mustered their forces for another offensive under the new and capable Grand Vizier Gazi Hüsrev Pasha. A severe winter and heavy floods made operations in central Iraq impossible, and Hüsrev turned his army east instead, invading Persia proper. On 4 May 1630 he routed the Persians under Zainal Khan Begdeli Shamlu in battle at Mahidasht near Kermanshah and proceeded to sack the city of Hamadan. Hüsrev Pasha then turned back towards Baghdad and besieged it in November. However the siege had to be lifted soon, as the onset of another heavy winter threatened his lines of communication. In the wake of his withdrawal, the Persians re-established their control of Iraq, and subdued the rebellious Kurdish populations. The next few years saw constant raiding and skirmishes, without either side claiming any decisive advantage. Shah Safi (r. 1629–42) sent a peace delegation to the Ottoman court, but the new Grand Vizier, Tabanıyassi Mehmed Pasha, rejected its demands. The Caucasian front of the Persians flared up again in 1633, when the restless Georgian kingdoms of Kartli and Kakheti, under the rule of King Teimuraz, defied Safavid sovereignty. In 1634, Rustam Khan, a Georgian convert to Islam, was sent by the Shah to subdue them. Teimuraz was defeated, but managed to escape to safety in Imereti. He would nevertheless manage to restore himself on the throne of Kakheti in 1638, and even win Persian recognition of this fact.

In 1635, in a conscious effort to emulate his warrior predecessors, Sultan Murad IV himself took up the leadership of the army. The Ottomans took Revan (on 8 August) and plundered Tabriz. The victorious Sultan returned in triumph to Constantinople, but his victories were short-lived: in the spring of the next year, Shah Safi retook Revan and defeated an Ottoman army. Renewed Persian peace proposals failed, and in 1638, Murad IV again personally led an army against Baghdad. The city fell in December after a siege of 39 days, effectively restoring Ottoman control over Iraq, and peace negotiations began soon after.

Aftermath
The Treaty of Zuhab, concluded on 17 May 1639, finally settled the Ottoman–Persian frontier, with Iraq permanently ceded to the Ottomans. Mesopotamia, which had formed an important part of various Persian empires from the time of the Achaemenids, was thereby irrevocably lost. The rest of the borders were restored roughly according to the way they were in 1555, with Eastern Armenia, Dagestan, eastern Georgia, and the contemporary Azerbaijan Republic remaining Persian, while Ottoman gains in Western Georgia and Western Armenia were made decisive. In broad terms, the Treaty of Zuhab reconfirmed the provisions of the 1555 Peace of Amasya. Eastern Samtskhe (Meskheti) was irrevocably lost to the Ottomans as well, making Samtskhe in its entirety an Ottoman possession. The peace established a permanent equilibrium of power in the region, and despite future conflicts and minor adjustments, the frontier postulated by the treaty remains to this day the western border of Iran with Iraq and Turkey.