Legacy of Mohammud Ghazni

By the end of his reign, the Ghaznavid Empire extended from Ray in the west to Samarkand in the north-east, and from the Caspian Sea to the Yamuna. Although his raids carried his forces across the Indian subcontinent, only a portion of the Punjab and of Sindh in modern-day Pakistan came under his semi-permanent rule; Kashmir, the Doab, Rajasthan, and Gujarat remained under the control of the local Hindu dynasties.

The booty brought back to Ghazni was enormous, and contemporary historians (e.g. Abolfazl Beyhaghi, Ferdowsi) give descriptions of the magnificence of the capital, as well as of the conqueror's munificent support of literature. He transformed Ghazni, the first centre of Persian literature, into one of the leading cities of Central Asia, patronizing scholars, establishing colleges, laying out gardens, and building mosques, palaces, and caravansaries. Mahmud brought whole libraries from Ray and Isfahan to Ghazni. He even demanded that the Khwarizmshah court send its men of learning to Ghazni.

Mahmud patronized the notable poet Ferdowsi, who after laboring 27 years, went to Ghazni and presented the Shahnameh to him. There are various stories in medieval texts describing the lack of interest shown by Mahmud to Ferdowsi and his life's work.

According to historians, Mahmud had promised Ferdowsi a dinar for every distich written in the Shahnameh (which would have been 60,000 dinars), but later retracted his promise and presented him with dirhams (20,000 dirhams), at that time the equivalent of only 200 dinars.

His expedition across the Gangetic plains in 1017 inspired Al-Biruni to compose his Tarikh Al-Hind in order to understand the Indians and their beliefs. During Mahmud's rule, universities were founded to study various subjects such as mathematics, religion, the humanities, and medicine.

On 30 April 1030 Sultan Mahmud died in Ghazni at the age of 58. Sultan Mahmud had contracted malaria during his last invasion. The medical complication from malaria had caused lethal tuberculosis.

The Ghaznavid Empire was ruled by his successors for 157 years. The expanding Seljuk empire absorbed most of the Ghaznavid west. The Ghorids captured Ghazni in 1150, and Mu'izz al-Din (also known as Muhammad of Ghori) captured the last Ghaznavid stronghold at Lahore in 1187.

The military of Pakistan has named its short-range ballistic missile the Ghaznavi Missile in honour of Mahmud of Ghazni. In addition, the Pakistan Military Academy, where cadets are trained to become officers of the Pakistan Army, also gives tribute to Mahmud of Ghazni by naming one of its twelve companies Ghaznavi Company.

The 2005 Indian Tamil-language revenge film Ghajini by A. R. Murugadoss, about an amnesiac businessman, is named after the sultan (whose name is pronounced "Ghajini" in Tamil) in reference to his persistent efforts despite several failures.

The film was later remade in Hindi in 2008 with the same name which was also adapted as a videogame titled Ghajini – The Game.