A Vizier (وزير, sometimes also spelled Wazir) is an Arabic term for a high-ranking religious and political advisor, often to a king or sultan. During the days of the Ottoman Empire the Grand Vizier played the role of a pseudo-prime minister in the Sultan's court and was the leader of the Divan, the Imperial Council.
In some societies, unsuccessful viziers were commonly put to death. This was particularly common during much of Ottoman history; for example, one of the most brutal sultans, Selim I, had seven viziers executed during his eight-year rule.
In ancient Egypt the second important person after the pharaoh was the vizier as a general governor. Among the Huns, the vizier was the second in rank officer after the great king. Attila the Hun's vizier was Onegesius.
In contemporary literature, the "Grand Vizier" is a character stereotype and is usually portrayed as a scheming backroom plotter and the clear power behind the throne of a usually bumbling or incompetent monarch. A well-known example of this is the sinister character of Jafar in the Disney movie Aladdin who plots to take over the entire Kingdom of Agraba under the nose of the nation's na´ve sultan. Others include the villains of the video games Prince of Persia and King's Quest 6.
Perhaps the origin of this character archetype is the biblical account of Esther. The book details the rise of a Jewish woman to Queen of Persia, and her role in stopping the plot of Hamman, chief advisor to the Persian king, to wipe out all Jews living in Persia.
Throughout history the notion of the sinister Grand Vizier has often been evoked when a political leader appears to be developing a cozy relationship with a spiritual advisor of questionable scruples or talents.