Al-Malik az-Zahir Ghazi ibn Yusuf ibn Ayyub (commonly known as az-Zahir Ghazi; 1172 – 8 October 1216) was the Ayyubid emir of Aleppo between 1186 and 1216. He was the third son of Saladin and his lands included northern Syria and a small part of Mesopotamia.
In 1186, when az-Zahir was 15 years of age, his father appointed him governor of Aleppo, Mosul and supporting areas which had recently been taken from the Zengids. At the same time his two older brothers were appointed, respectively, as governor of Syria (al-Afdal) and Egypt (al-Aziz). The lands that az-Zahir received had been under the control of his uncle, Saladin's brother al-Adil, and al-Adil took an avuncular interest in az-Zahir. As the third son, when he inherited in 1193 he was to owe suzerainty to his eldest brother, al-Afdal, in Damascus. However, he failed to do so, and he conducted his affairs independently from his brothers.
In 1193, faced with the ongoing revolt of Zengid 'Izz al-Din in Mosul, he called upon his uncle, al-Adil, to provide the forces to suppress the revolt, which was quickly quelled. In 1194 az-Zahir received Latakia as part of a settlement in which he recognized al-Afdal's authority. However, by 1196 al-Afdal had proved himself incompetent as a ruler, and had lost the support of his uncle, al-Adil. Az-Zahir joined with his brother al-Aziz and uncle al-Adil in deposing and exiling al-Afdal. In October 1197, noting that Amalric of Lusignan had retaken the port at Beirut and that Bohemond III of Antioch was threatening the ports of Latakia and Jableh, az-Zahir destroyed the ports. Although Bohemond took the two locations, they were no longer advantageous, and he soon withdrew. At which point az-Zahir reoccupied them, and rebuilt the fortress at Latakia.
While ruler in Aleppo he kept many of his father's advisors. He appointed Baha ad-Din as a qadi ("judge") in Halab. He brought the unorthodox as-Suhrawardi to Halab, but was forced to imprison him in 1191 due to the demands of the orthodox ulama ("men of learning").
When al-Aziz died in Egypt in 1198 and was succeeded by his son al-Mansur, a boy of nine, al-Aziz's ministers, worried about the ambitions of al-Adil, summoned al-Afdal from exile to act as Regent of Egypt in the name of his young nephew. Early in the next year, while al-Adil was in the north suppressing an Artuqid rebellion, al-Afdal and az-Zahir came together in alliance and were joined by most of the other Ayyubid princes. Together they besieged Damascus, but as it held out for several months az-Zahir, as did other Ayyubid princes, lost interest and withdrew his troops. Al-Adil was not pleased and after conquering Egypt, he returned and reduced az-Zahir's territories to the area around Aleppo, forcing him to recognize overarching al-Adil suzerainty. During the last decade of his life he skirmished with crusaders and lent his army to support other Ayyubid princes. In 1206, King Leo of Cilicia defeated az-Zahir forces at the Battle of Amq, but was unable to secure any permanent advantage against Aleppo. In 1207, the French attacked and besieged Homs and its emir, an Ayyubid prince called Mujadid Shirkuh II, appealed to az-Zahir, whose troops lifted the siege.
Of particular importance was az-Zahir's marriage in 1212 to Dayfa Khatun, the daughter of his old rival al-Adil. This marked the end of the rivalry between the two branches of the family.
Prior to his death in 1216, az-Zahir appointed his younger son al-Aziz Muhammad (b. 1213) to succeed him.