The Ottoman Empire used anthems since its foundation in the late 13th century, but did not use a specific royal or national anthem until the 19th century. During the reign of Sultan Mahmud II, when the military and imperial band were re-organized along Western lines, Giuseppe Donizetti was invited to head the process. Donizetti Pasha, as he was known in the Ottoman Empire, composed the first Western-style imperial anthem, the Mahmudiye.
Like in many other monarchies of its time, the anthem of the Ottoman Empire was a royal anthem, not a national one. Hence it paid homage to a specific ruler and a new anthem was composed at each imperial succession. However, in 1844, with the Tanzimat reforms, the was recognized as the first official Ottoman national anthem. The first official Ottoman national flag (which was in essence identical to the present-day Turkish flag) was also adopted in 1844.
After the start of the imperial anthem tradition, two Sultans did not have specific anthems composed. The first is Sultan Murad V, who reigned for 3 months in 1876 and the second is the last Sultan of the Ottoman Empire, Sultan Mehmed Vahdeddin, who used the Mahmudiye anthem.
Only the Hamidiye and Reşadiye have lyrics, the first three anthems being melodic.