Ghaznavid campaigns in India

The Ghaznavid campaigns in India refer to a series of military expeditions lasting 54 years (973–1027) launched by the Ghaznavid Empire, a prominent empire of the 10th and 11th centuries, into the Indian subcontinent, led primarily by Sultan Mahmud of Ghazni ((r. 998 – 1030)), leaving a profound impact on the region's history and culture.

Beginning in the late 10th century, these incursions marked a significant chapter in the history of South Asia, with Ghaznavid forces penetrating deep into the Indian subcontinent, including the Punjab region and northern India. The primary objectives of these campaigns included the acquisition of wealth, the propagation of Islam, and the establishment of Ghaznavid rule in the region.

By the end of the tenth century, the Ghaznavid ruler Sabuktigin captured the region between Laghman and Peshawar from the Hindu Shahi ruler Jayapala. This laid the foundation for the Ghaznavids to establish their dominance over parts of present-day Afghanistan and northern India. The Ghaznavid campaigns in India serve as a crucial historical backdrop to the later Islamic empires that would shape the subcontinent's destiny.

Campaign timeline
This list details the military campaigns conducted by the Ghaznavids in India.

Under Sabuktigin
Sabuktigin was one of the slaves of Alptigin, the Governor of Ghazni. Alptigin was succeeded by his son Abu Ishaq and his slave, Bilgetigin, respectively. Following Bilgetigin's death in 972, another of Alptigin's slaves, named Boritigin, ascended to the throne.

Battle of Charkh (973)
The first military conflict between Sabuktigin and the Indian kingdoms occurred in 973, when Abu Ali Lawik, the king of the Lawik dynasty, marched to invade Ghazni. Jayapala, the Hindu Shahi ruler, sent his son to support Lawik in this invasion. The battle took place near Charkh, in modern-day Afghanistan. Sabuktigin's forces defeated the combined armies of Lawik and the Hindu Shahis, resulting in the death and capture of many of their soldiers. Abu Ali Lawik himself was killed in the battle.

As a Ghaznavid ruler
Sabuktigin ascended to the throne of Ghazni in 977, and embarked on a series of wars with Indian kingdoms in the late 10th century. His primary objective was to expand the influence of the Ghaznavid Empire in the Indian subcontinent. Sabuktigin's most remarkable military achievement was the conquest of the Punjab region. These conflicts with Indian kingdoms solidified the Ghaznavids as a formidable power in India and laid the groundwork for the more renowned invasions led by Mahmud of Ghazni in the subsequent century.

Initially, Sabuktigin faced opposition from Toghan and subsequently marched against him, leading to the capture of Kandahar and its surrounding areas. Sabuktigin also conducted raids in the territories belonging to Jayapala, which provoked Jayapala to launch an attack on Ghazni.

First Battle of Laghman
The first Battle of Laghman took place in 988 near present-day Laghman, Afghanistan, between Jayapala and Sabuktigin. Sabuktigin's Ghaznavid forces emerged victorious over Jayapala's Hindu Shahi forces. As a result, Jayapala, the Hindu Shahi ruler, was compelled to pay a substantial tribute to Sabuktigin and cede both territories and a few forts

Second Battle of Laghman
To avenge the defeat at Laghman, Jayapala orchestrated the formation of a confederacy comprising Hindu chiefs from the Tomara dynasty, Gurjara-Pratihara dynasty, Chahamanas, and Chandelas. This alliance was aimed at preparing for a pivotal battle. Jayapala amassed a substantial force, which included 100,000 cavalry and an immense contingent of foot soldiers. In 991 AD, Both forces met at Laghman. Seeing the disproportion of the manpower, Sabuktigin divided his troops into squadrons of 500 men each, and directed them to attack the enemy on one particular point. Ghaznavid forces again defeated the combined Hindu Shahi and Rajput forces.

Sabuktigin died in 997. He had increased Alptigin's domains to cover the area south of the Hindu Kush in Afghanistan and east to the Indus River in what is today Pakistan. His son Mahmud of Ghazni succeeded him.

Under Mahmud of Ghazni
Mahmud of Ghazni succeeded Sabuktigin in 997. Mahmud of Ghazni's invasion of India in the 11th century was a pivotal moment in the subcontinent's history. Mahmud, a powerful Turkic ruler, launched a series of raids into India between 1000 and 1027. His primary goal was to plunder the rich temples of northern India, most notably the famous Somnath Temple. These invasions left a lasting impact on the Indian subcontinent, both culturally and politically. While Mahmud's conquests were driven by a desire for wealth and power, they also led to the spread of Persian culture and the introduction of Islam in the region. His expeditions marked the beginning of a series of foreign invasions into India, ultimately shaping the course of its history for centuries to come.

Against the western front


In 1001, the Ghaznavid forces, led by Mahmud of Ghazni, achieved victory over the Hindu Shahi forces, commanded by Jayapala, near Peshawar. Consequently, Mahmud incorporated Peshawar and Punjab into his empire. Jayapala, the Hindu Shahi ruler, was taken prisoner and, in the face of the humiliating defeat, immolated himself.

In 1004 CE, Mahmud invaded the Kingdom of Bhatia/Bhera and defeated its ruler, Biji Rai (also known as Baji Rao). The battle raged on for three days, resulting in heavy casualties for Biji Rai's forces. Ultimately, Biji Rai was compelled to retreat into the forest. The city came under siege and was eventually conquered by Sultan Mahmud's army. Biji Rai was captured by the Ghaznavids but chose to take his own life. Mahmud amassed significant wealth from this battle, including 120 elephants. Mahmud returned to Ghazni after this campaign.

In 1006, Mahmud led an expedition against Fateh Daud, the king of the Lodi dynasty of Multan. Daud had formed an alliance with Anandapala, the son of Jayapala, who had taken the throne after his father's death. Mahmud initially requested Anandapala to allow his army to pass through his territory, but Anandapala, being in alliance with Daud, refused. Consequently, Mahmud marched against Anandapala and defeated his forces near the Indus River. Anandapala was compelled to retreat to the mountains of Kashmir. Mahmud's forces plundered Anandapala's territories and took many soldiers as prisoners.

Mahmud continued his march towards Multan and, upon reaching the city, Fateh Daud surrendered it to him and agreed to pay an annual tribute. On his way back to Ghazni, Mahmud appointed a Hindu convert named Nawassa Shah (also known as Sukhapala) to oversee the Indian territories. Sukhapala happened to be the grandson of Jayapala.

In Mahmud's absence, Sukhapala reverted to Hinduism and revolted against him. Mahmud, upon hearing this, marched from Ghazni to Multan and defeated Sukhapala. Sukhapala retreated to the Salt Ranges but was eventually captured by the Sultan's forces and taken as a prisoner. Mahmud compelled Sukhapala to pay 400,000 dirhams and sentenced him to life imprisonment.

In 1008, Mahmud launched a campaign against the Hindu Shahis and defeated Anandapala in the Battle of Chach. This conflict likely arose from Anandapala's support of Daud during Mahmud's invasion of Multan. The Hindu Shahi troops retreated as far as the Kangra Valley, where they sought refuge.

In 1009, Mahmud embarked on an expedition against the King of Narayana, a Rajput vassal state of Anandapala. Anandapala intervened to aid his vassal but was ultimately defeated by Mahmud's Ghaznavid forces. This conquest allowed Mahmud to penetrate deep into the heartland of India.

In 1010, Daud staged another revolt against Mahmud. Mahmud responded by marching towards Multan, where he not only quelled the rebellion but also inflicted heavy casualties among heretics and took Daud as a prisoner. This action reestablished Mahmud's authority over Multan.

After experiencing a series of consecutive defeats, Anandapala opted to initiate a peace treaty with Mahmud. The terms of the agreement stipulated that he would annually pay a substantial tribute equivalent to the profits generated from his territories and the looting of his cities. Additionally, he committed to sending 50 elephants and 2000 well-trained armed personnel for military support. In exchange, the Sultan pledged not to launch any invasions into Anandapala's kingdom.

Other campaigns
Despite his alliance with Anandapala, Mahmud of Ghazni continued his military campaigns in India. In 1012 CE, Mahmud marched from Ghazni to Thanesar with the intent to conquer and plunder the city. According to their treaty, Anandapala allowed Mahmud to pass through his territory but requested that the sacred city not be destroyed. Nevertheless, Mahmud continued his march toward Thanesar and encountered resistance from Rama, the chief of Dera, whom Mahmud defeated, allowing him to proceed further.

In 1012, Thanesar was under the rule of the Tomara dynasty. The Tomara king sent appeals for assistance to other neighboring kings, but Mahmud successfully captured the city, plundered it, and then returned to Ghazni. Anandapala's death is not recorded in any chronicle; however, it can be ascertained to be c. late 1010 - early 1011. His son Trilochanapala succeeded him.

After the demise of Anandapala, Mahmud of Ghazni resumed his campaigns against the Hindu Shahis. In 1014 CE, he launched an expedition against Trilochanapala, who had settled in Nandana within the Salt Range. Trilochanapala attempted to defend the fort, but his forces were defeated by the Ghaznavid army, leading to the capture of the fort of Nandana. Trilochanapala fled to Kashmir to escape capture.

Mahmud pursued Trilochanapala into the Kashmir hills, pillaging villages along his path as he advanced towards Kashmir. This marked Mahmud's first invasion of Kashmir in 1015 AD. Seeking assistance, Trilochanapala turned to Sangramaraja, the reigning Lohara king of Kashmir, who promptly dispatched a substantial force led by his commander, Tungh, to support Trilochanapala. Initially, Tungh's forces won a skirmish against a small detachment sent by Mahmud. However, their overconfidence led them to engage in an open battle. Despite being outnumbered, Mahmud's Ghaznavid forces managed to defeat the Kashmiri forces. Trilochanapala retreated from the battlefield, and Mahmud plundered the frontier of the Kashmir valley before returning to Ghazni.

In 1016, Mahmud launched another invasion of Kashmir, advancing until he reached the pass where the fort of Lohkot is located. Mahmud initiated a siege of the fort, but his efforts were interrupted by the onset of winter, accompanied by heavy snowfall. Consequently, Mahmud had to withdraw from the operation due to the adverse weather conditions.

In 1018 AD, Mahmud led an expedition against the Gurjara-Pratihara dynasty. Sultan Mahmud marched from Ghazni to Kannauj with a formidable army. Along his journey, he reached Bulandshahr, where King Hardat of Bulandshahr fled, leaving a garrison to defend the fort. The Ghaznavid forces defeated this garrison, and peace was secured with a payment of 1,000,000 dirhams and 30 elephants. Continuing his advance, Mahmud reached Mahaban. The king of Mahaban, named Kulchand, retreated to a dense forest and prepared for a battle. However, the forces of Mahaban were defeated by the Ghaznavids and many of them perished, some drowning in the river Yamuna. In a tragic turn of events, Kulchand took the life of his wife and then his own He subsequently launched an attack on Mathura. Although it was under the control of the Tomara dynasty, he did not encounter significant opposition. Mahmud plundered and devastated Mathura, leaving it in ruins. From Mathura, he advanced towards Kannauj. Upon his approach, Rajyapala, the Gurjar King, retreated to a location known as Bari. Kannauj fell easily to the Ghaznavids due to the lack of resistance. Eventually, Rajyapala surrendered to the Sultan. Mahmud then took control of Munjhawan, a Brahmin stronghold. The garrison put up a spirited defense against the invasion for 25 days but was ultimately defeated. Tragically, many of the defenders, along with their wives and children, chose to immolate themselves in the fire, while others leaped from the fort onto the battlefield, preferring death over dishonor. In the end, it was discovered that no one had survived within the fort.

Mahmud then advanced towards Asi, but its ruler Chandrapal Bhur ran away from his territory. By Sultan's order, the fort was plundered and the inhabitants were put to death.

In January 1019, Mahmud marched towards Sirsawa. Chand Rai, the Hindu chief of that region, prepared for battle. However, before the Sultan's arrival, Bhimpala, the son of Trilochanapala, advised him not to engage in a battle with Mahmud. Consequently, he fled from his fort, sought refuge on a hill, and concealed himself in a dense forest. Mahmud reached Sirsawa, plundered the fort, and then led his army into the forest, capturing Chand Rai.

"'Sultan Mahmud is not like the rulers of Hind and is not the leader of black men. It is obviously advisable to seek safety from such a person, for armies flee away before the very name of him and his father. I regard his bridle as much stronger than yours, for he never con- tents himself with one blow of the sword nor does his army satisfy itself with one hill out of a whole range. If, therefore, you design to contend with him, you will suffer; but do as you like-you know best. If you wish for your own safety, you will remain in concealment.'"

By the time, Rajyapala, the Gurjar ruler who surrendered to Mahmud was killed by the Chandela ruler Vidhyadara. In 1021, Mahmud marched from Ghazni with the intention of punishing Vidhyadara for his actions. However, he faced opposition from Trilochanapala on the banks of the Rahib River (either Yamuna or Ravi). Trilochanapala's army was defeated by the Ghaznavid forces, compelling him to retreat from the battlefield, resulting in the loss of many of his soldiers. Trilochanapala himself passed away shortly after the battle, and his son Bhimpala succeeded him.

Mahmud attacked the territories of Vidhyadara. He attacked the Gwalior fort in 1021 and forced its Kachchhapaghata ruler Kirthiraja to surrender. Kirthiraja accepted the nominal suzerainity of the Sultan and became a vassal of Ghaznavids. Kirthiraja offered thirty five war elephants to Mahmud.

Mahmud then directed his attention towards Kalinjar, where Vidhyadara had sought refuge after the Battle of the Rahib. The Sultan laid siege to the fort of Kalinjar, and after a fierce conflict, both parties opted for a peace treaty. Vidhyadara composed a poem praising Mahmud of Ghazni, and in a gesture of goodwill, Mahmud returned 15 forts to Vidhyadara as a part of the agreement.

Sack of Somnath in Gujarat
In 1026, Mahmud of Ghazni led an army of 80,000 men on a campaign to plunder the Somanath temple. Rajput forces opposed his army at Somanath, but the Sultan's forces emerged victorious, with a devastating toll of 50,000 casualties among the defending army. The Ghaznavids looted the Somanath temple and destroyed its idols. This event earned Mahmud the title of 'The Idol Breaker' due to his actions during this campaign.

Mahmud defeated the Jatts near the Indus River in 1027.