As a symbol of sovereignty in the Middle Ages and patriotism in modern times, as well as a tool of political and military propaganda, the flag (Ar. ʿalam , Turk. sancak , Pers. dirafsh ) has played an integral role in the formation of dynastic and religious identity in the Islamic world. Like many other customs that the Muslims adopted and adapted in the course of their conquests, ideas of banners and standards were derived from those evolved in Roman and Sāsānian territories, but such signaling devices were also combined with pre-Islamic