The Ghaznavids and Seljuqs

The Ghaznavid Campaign in Gandhara and Northwestern India

After Mahmud of Ghazni was repulsed in 1008 in his attack on the Qarakhanid Empire to his north, he enlisted the Seljuq Turks in southern Sogdia and Khwarazm to defend his kingdom from Qarakhanid retribution. The Seljuqs were an enslaved Turkic tribe that had been used as defense forces by the Samanids and had converted to Islam in the 990s. Having secured his homeland, Mahmud now turned his attention back to the Indian subcontinent.

Several decades earlier, in 969, the Fatimids (910 – 1171) had conquered Egypt and had made it the center of their rapidly expanding empire. They were seeking to unite the entire Muslim world under their banner of the Ismaili sect in preparation for the coming of the Islamic messiah, an apocoplyptic war, and the end of the world, predicted for the beginning of the twelfth century. Their domain extended from northern Africa to western Iran and, as a major sea power, they sent missionaries and diplomats far afield to extend their influence and faith. They were the major rivals of the Sunni Abbasids for the leadership of the Islamic world.

The vestiges of Muslim rule in Sindh after the Umayyad conquest were extremely weak. Sunni governors paid nominal allegiance to the Abbasid caliph, while in fact sharing power with local Hindu rulers. Islam coexisted peacefully with Buddhism, Hinduism, and Jainism. Ismaili missionaries, however, found a receptive audience among Sunnis and Hindus there dissatisfied with the status quo. By 959, the ruler of Multan, northern Sindh, converted to Ismaili Shia and, in 968, Multan declared itself an Ismaili Fatimid vassal state, independent of the Abbasids. At this point, the Abbasids, joined by their Ghaznavid vassals, were surrounded to the east and west by their Fatimid rivals. They feared an impending two-front invasion. To attack the Ghaznavids, the Ismailis of Multan would merely need to pass through the territory of the Ghaznavid enemies, the Hindu Shahis.

Although his father had favored the Shiite form of Islam, Mahmud of Ghazni had adopted Sunni, the predominant faith of not only the Abbasids, but also of the Qarakhanids and Samanids. He was infamous for being intolerant of other forms of Islam. After ascending to the throne in 998 and consolidating his power in Afghanistan, he attacked the Hindu Shahis in Gandhara and Oddiyana in 1001 and defeated his father’s enemy, Jayapala, whom he also perceived as a potential threat. Although Oddiyana was still a main center of Buddhist tantra, with both King Indrabhuti and Padmasambhava having hailed from there prior to the Hindu Shahi rule, it lacked any flourishing Buddhist monasteries. Its Hindu temples, on the other hand, abounded with wealth. Consequently, Mahmud looted and destroyed them.

Jayapala’s successor, Anandapala (r. 1001 to 1011), now formed an alliance with Multan. But by 1005, Mahmud defeated their joint forces and annexed Multan, thus neutralizing the Fatimid Ismaili threat to the Sunni Abbasid world from the east. Mahmud called his troops “ghazi,” warriors for the faith, and termed his campaign a “jihad” to defend orthodox Sunni observance against the heresy of Ismaili Shia. Although religious zeal might have been part of his motivation, a greater part was undoubtedly his wish to establish himself as the defender of the Abbasids as leaders of the Islamic world. Playing such a role would legitimize his own rule as an Abbasid vassal and the loot that he plundered would help finance anti-Fatimid campaigns of the Abbasids elsewhere. For example, the ancient Hindu sun temple, Suraj Mandir, in Multan, was reputedly the wealthiest temple of the Indian subcontinent. Its treasures only increased Mahmud’s thirst for more riches, further to the east.

After Mahmud’s unsuccessful campaign against the Qarakhanids, he returned to the Indian subcontinent and, in 1008, defeated an alliance between Anandapala and the Rajput rulers in present-day Indian Punjab and Himachal Pradesh. He confiscated the enormous Hindu Shahi treasury in Nagarkot (present-day Kangra), and, over the next years, plundered and destroyed the wealthy Hindu temples and Buddhist monasteries in the area. Among the Buddhist monasteries that he destroyed were those in Mathura, south of present-day Delhi.

In 1010, Mahmud quashed a rebellion in Multan and, in either 1015 or 1021 (depending on which source one accepts), he pursued the next Hindu Shahi ruler, Trilochanapala (r. 1011 – 1021), who was consolidating his forces at Lohara fort in the western foothills leading to Kashmir. Mahmud, however, was never able to take the fort, or to invade Kashmir. It is unclear how strong a role the Hindu founder of the First Lohara Dynasty of Kashmir (1003 – 1101), Samgrama Raja (r. 1003 – 1028), played in Mahmud’s defeat. According to traditional Buddhist accounts, the Ghaznavid ruler was stopped by Buddhist mantras recited by Prajnarakshita, a disciple of Naropa.

Due to the heavy damage that Mahmud’s forces inflicted on the Buddhist monasteries in Indian Punjab and Himachal Pradesh, many Buddhist refugees sought asylum elsewhere. But, with the Ghaznavid troops attacking in the direction of Kashmir, most refugees did not feel secure in fleeing there. Such a large number flooded instead across the Himalayas via Kangra to Ngari in western Tibet that in the 1020s its king passed a law restricting foreigners from staying in the country more than three years.

In summary, the Ghaznavid jihad in the Indian subcontinent was originally directed against the Ismailis, not the Buddhists, Hindus, or Jains. However, once Mahmud had accomplished his religious and political goal, his victory incited him to gain further territory and especially loot from the wealthy Hindu temples and Buddhist monasteries in them. As with the Umayyad campaign three centuries earlier, the Turkic forces destroyed temples and monasteries, after thoroughly looting them, as part of their initial conquest of areas, but did not seek to impose Islam on all their new subjects. Mahmud was pragmatic and utilized unconverted Hindu troops and even a Hindu general against Shiite Muslims who resisted him in Buyid Iran. His main target remained the Shiites and Ismailis.

Ghaznavid Attitudes toward Buddhism outside India

Al-Biruni, the Persian historian who accompanied Mahmud’s invasion of the Indian subcontinent, spoke favorably of Buddhism and wrote that Indians referred to Buddha as a “Prophet.” Perhaps this indicates his familiarity with the Middle Persian term burxan, meaning prophet, used for “Buddha” in Sogdian and Uighur Buddhist texts, and earlier in Manichaean texts for all prophets. It may also indicate, however, that the Buddhists were accepted as “people of the Book” and, along with the Hindus and Jains, afforded protected subject dhimmi status after the initial destruction.

Further evidence to support this second conclusion is that the Ghaznavids did not persecute Buddhism in their earlier holdings in Sogdia, Bactria, or Kabul. In 982, Buddhist frescoes were still visible in Nava Vihara and the colossal Buddha figures carved in the cliffs of Bamiyan in central Afghanistan were still undamaged. Al-Biruni reported many Buddhist monasteries still functioning on the southern borders of Sogdia at the turn of the millennium.

Like the Samanids before them, the Ghaznavids promoted Persian culture. Both Persian and Arabic literature, from the ninth through the twelfth centuries, abounded with references to the beauty of the Buddhist monuments, indicating that monasteries and mosques functioned peacefully, side by side. For example, Asadi Tusi described the splendor of Subahar Monastery of Kabul in his 1048 work, Garshasp Name. Persian poetry often used the simile for palaces that they were as beautiful as a “Nawbahar” (Nava Vihara).

Buddha images, particularly of Maitreya, the future Buddha, were depicted at Nava Vihara and Bamiyan with moon discs behind their heads. This led to the poetic depiction of pure beauty as someone having “the moon-shaped face of a Buddha.” Thus in eleventh century Persian poems, such as Varqe and Golshah by Ayyuqi, the Pahlavi word bot, deriving from the earlier Sogdian term purt, is used with a positive connotation for “Buddha,” not with its second, derogatory meaning as “idol.” It implies the ideal of asexual beauty, and is applied equally to both men and women.

It is unclear whether the Arabic word al-budd derives from the Persian or was coined directly at the time of the Umayyad conquest of Sindh. Originally, the Umayyads used the term for both Buddhist and Hindu images, as well as the temples that contained them. Occasionally, they used it as well for any non-Muslim temple, including Zoroastrian, Christian, and Jewish. Later, however, it too came to have both a positive and a negative meaning as “Buddha” and “idol.”

All these references indicate that either Buddhist monasteries and images were present in these Iranian cultural areas at least through the early Mongol period in the thirteenth century or, at minimum, that a strong Buddhist legacy remained for centuries among the Buddhist converts there to Islam. If the Ghaznavids tolerated Buddhism in their non-Indian lands and even patronized literary works extolling its art, it seems unlikely, then, that their long-term policy on the subcontinent was one of conversion by the sword. As with the Umayyads, the Ghaznavid manner of conquest was not the same as their manner of rule.

The Decline of the Ghaznavids and Rise of the Seljuqs

Despite their military successes on the Indian subcontinent, the Ghaznavids were unable to control the Seljuqs under them, and in 1040 the latter rebelled. The Seljuqs took over Khwarazm, Sogdia, and Bactria from the Ghaznavids and, in 1055, conquered Baghdad, the seat of the Abbasid caliphs.

Map 28: The Seljuq Empire, Second Half of the Eleventh Century
Map 28: The Seljuq Empire, Second Half of the Eleventh Century

The Seljuqs were Sunnis and as adamantly anti-Shiite and anti-Ismaili as were the Ghaznavids. They were anxious to wrest the caliphs from the influence and control of the Buyid Shiites in Iran. In 1062, they finally conquered the Buyid Kingdom and, the next year, proclaimed their own empire. The final parts of the Seljuk Empire lasted until submitting to the Mongols in 1243.

In face of their defeat to the Seljuks, the Ghaznavids withdrew to the east of the Hindu Kush Mountains, restricted to Ghazna, Kabul, and the Punjab. They maintained a military force enlisted from the various Muslim Turkic mountain tribes in their realm, and relied on taxes gathered from the wealthy non-Muslims of the Indian subcontinent to finance their state. Their policy toward Kashmir clearly exemplifies their attitude toward other religions.

The Political and Religious Situation in Kashmir

From 1028 until the end of the First Lohara Dynasty in 1101, Kashmir underwent a steady decline in economic prosperity. Consequently, the Buddhist monasteries suffered from minimal financial support. Furthermore, cut off by Ghaznavid territory from easy access to the great Buddhist monastic universities of the central part of northern India, the standards at the Kashmiri monasteries gradually declined. The last king of this dynasty, Harsha (r. 1089 – 1101), instituted yet another religious persecution, this time razing both Hindu temples as well as Buddhist monasteries.

During the Second Lohara Dynasty (1101 – 1171), and especially during the reign of King Jayasimha (r. 1128 – 1149), both religions recovered once more with royal support. However, the economic situation of the kingdom as a whole declined even further, continuing through the subsequent succession of Hindu rulers as well (1171 – 1320). Although the monasteries were impoverished, Buddhist activity flourished until at least the fourteenth century, with teachers and translators periodically visiting Tibet. Yet, despite Kashmir’s weakness for more than three centuries, neither the Ghaznavids nor their Muslim successors in India sought to conquer it until 1337. This is further indication that the Islamic rulers were more interested in gaining riches than converts from the Buddhist monasteries. If the latter were poor, they left them alone.

Seljuq Expansion and Religious Policy

Meanwhile, the Seljuqs expanded their empire westward, conquering the Byzantines in 1071. The Seljuq sultan, Malikshah (r. 1072 – 1092), imposed his overlordship upon the Qarakhanids in Ferghana, northern West Turkistan, Kashgar, and Khotan. Under the influence of his minister, Nizamulmulk, the Seljuqs built religious schools (madrasah) in Baghdad and throughout Central Asia. Although madrasahs had first arisen in ninth century northeastern Iran, devoted to purely theological study, these new madrasahs were oriented toward supplying a civil bureaucracy for the Seljuqs that was well educated in Islam. The Seljuqs had a very pragmatic approach to religion.

Having opened Anatolia to Turkic settlement, the Seljuqs went on to take Palestine as well. The Byzantines appealed to Pope Urban II in 1096, who declared the First Crusade to reunite the Western and Eastern Roman Empires and win back the Holy Lands from the “infidels.” The Seljuqs, however, were by no means anti-Christs. They did not, for example, eradicate Nestorian Christianity from Central Asia.

Nor were the Seljuks particularly anti-Buddhist. Had they been, they would have either led or backed their Qarakhanid vassals in a holy war against the Tanguts, Qocho Uighurs, and Ngari Tibetans, all of whom were strongly Buddhist and militarily weak. On the contrary, during their rule of Baghdad, the Seljuqs allowed al-Shahrastani (1076 – 1153) to publish there his Kitab al-Milal wa Nihal – a philosophical text in Arabic containing an account of the Buddhist tenets and, like al-Biruni, referring to Buddha as a Prophet.

The Nizari Order of Assassins

The extremely negative image the European and Byzantine Christians had of the Seljuqs and Islam in general was partially due to their faulty identification of all of Islam with the Nizari branch of the Ismailis, known to the crusaders as the “Order of Assassins.” Starting in approximately 1090, the Nizaris led a terrorist revolt throughout Iran, Iraq, and Syria, with youths intoxicated on hashish being sent to assassinate military and political leaders. They wished to prepare the world for their leader, Nizar, to become not only caliph and imam, but Mahdi, the final prophet who would lead the Islamic world in a millenarian war against the forces of evil.

Over the next decades, the Seljuqs and Fatimids launched holy wars against the Nizaris, massacring them in large numbers. The Nizari movement eventually lost all popular support. These holy wars also had a devastating effect on the Seljuqs and, in 1118, the Seljuq Empire split into several autonomous sections.

Meanwhile, the Ghaznavids continued to weaken in power. They lacked the human resources to rule even their diminished kingdom. The Qarakhanids also declined in power. Consequently, the Ghaznavids and Qarakhanids were forced to become tributary states to the autonomous Seljuq province in Sogdia and northeastern Iran.

Top