The battle was fought by the Holy Roman Empire (led by the Habsburg monarchy) and the Polish–Lithuanian Commonwealth, both under the command of King John III Sobieski, against the Ottomans and their vassal and tributary states.
[24] On the political front, the Ottoman Empire had been providing military assistance to the Hungarians and non-Catholic minorities in Habsburg-occupied portions of Hungary.
There, in the years preceding the siege, widespread unrest had grown into open rebellion against Leopold I's pursuit of Counter-Reformation principles and his desire to suppress Protestantism.
In 1681 and 1682, clashes between the forces of Imre Thököly and the Holy Roman Empire (the border of which was then northern Hungary) intensified, and the incursions of Habsburg forces into central Hungary provided the crucial argument of Grand Vizier Kara Mustafa Pasha in convincing Sultan Mehmed IV and his Divan to allow the movement of the Ottoman army.
But the 15-month gap between mobilization and the launch of a full-scale invasion provided ample time for Vienna to prepare its defense and for Leopold to assemble troops from the Holy Roman Empire and form an alliance with Poland, Venice and Pope Innocent XI.
[19]: 656, 659 On 31 March, another declaration – sent by Grand Vizier Merzifonlu Kara Mustafa Pasha on behalf of Mehmed IV – arrived at the Imperial Court in Vienna.
[25][19]: 660 The main Ottoman army arrived at Vienna on 14 July; the city's only defense force was now that of Count Ernst Rüdiger von Starhemberg's 15,000 men.
[26][27] The King of Poland, John III Sobieski, prepared a relief expedition to Vienna during the summer of 1683, honoring his obligations to the treaty, and would depart from Kraków on 15 August.
Only days before, he had received news of the mass slaughter at Perchtoldsdorf,[29] a town south of Vienna, where the citizens had handed over the keys of the city after having been given a similar choice but were killed anyway.
[19]: 660 In response to this Kara Mustafa Pasha would order his forces to dig long lines of trenches directly toward the city, to help protect them from the defenders as they advanced.
[19]: 660 Some historians have speculated that Kara Mustafa wanted to take the city intact with its riches and declined an all-out attack, not wishing to initiate the plundering that would accompany an assault, which was viewed as the right of conquering soldiers.
The command of the European allied forces was assigned to the Polish king, renowned for his extensive experience in leading campaigns against the Ottoman army.
Despite the multinational composition of the army and the short space of only six days, an effective leadership structure was established, centred around the king of Poland and his heavy cavalry (Polish Hussars).
The Holy League settled the issue of payment by using all available funds from the government, loans from several wealthy bankers and noblemen and large sums of money from the Pope.
[28][41] The combined besieging forces, led by Kara Mustafa, were less united and facing problems with motivation and loyalty, and struggled to prepare for the expected relief-army attack.
[43] Mustafa Pasha launched counterattacks with most of his forces, but held back some of the elite Janissary and Sipahi units for a simultaneous assault on the city.
Despite the arrival of the relief army, several Ottoman forces persisted in their attempts to breach the city's defenses, allowing Polish troops to advance on the field.
Imperial forces were now closing in on the central Ottoman position (the "Türkenschanze", now the Türkenschanzpark),[46] and as they made preparations for a final push, the Polish cavalry began to take action.
During this action they would begin to approach the Türkenschanze, which was now threatened by three separate forces (the Poles from the west, the Saxons and Bavarians from the northwest and the Austrians from the north).
The cavalry headed directly towards the Ottoman camps and Kara Mustafa's headquarters, while the remaining Viennese garrison sallied out of its defenses to join in the assault.
[19]: 661 The Ottoman forces were tired and dispirited following the failure of the sapping attempt, the assault on the city and the advance of the Holy League infantry on the Türkenschanze.
[18] Afterwards Sobieski paraphrased Julius Caesar's famous quotation (Veni, vidi, vici) by saying "Venimus, vidimus, Deus vicit"- "We came, we saw, God conquered".
Upon surrendering, however, the Ottomans gathered the men of the village in the market square, took their weapons, and massacred them; they captured the women and children and, as kafir war prisoners, took them away as slaves.
[6] The Holy League troops and the Viennese took a large amount of loot from the Ottoman army, which Sobieski described in a letter to his wife a few days after the battle: Ours are treasures unheard of ... tents, sheep, cattle and no small number of camels ... it is a victory as nobody ever knew before, the enemy now completely ruined, everything lost for them.
Due to his defeat at the battle, on 25 December Kara Mustafa Pasha was executed in Belgrade in the approved manner – by strangulation with a silk rope pulled by several men on each end – by order of the Janissary Agha.
[56] Further, Protestant Saxons, who had arrived to relieve the city, were reportedly subjected to verbal abuse by the Catholic populace of the Viennese countryside.
[57] The eunuchs, according to Professor Rudi Matthee "were not against the idea of having the Ottomans suffer some humiliation, but they did not want their power destroyed for fear that this would remove a buffer against Christian Europe".
[57] The victory at Vienna set the stage for a conquest of Hungary and (temporarily) lands in the Balkans in the following years by Louis of Baden, Maximilian II Emmanuel of Bavaria and Prince Eugene of Savoy.
The actions of Louis XIV of France furthered French–German enmity; in the following month, the War of the Reunions broke out in the western part of the weakened Holy Roman Empire.
Some have proposed that Al-Qaeda chose September 11, 2001 as the date to carry out terrorist attacks throughout the United States due to the day's perceived significance as the turning point in the Battle of Vienna.