The Shahi army broke when Anandapala’s elephant turned, and Mahmud went on to plunder Nagarkot.
01The near victory
Mahmud crossed the Indus at the end of 1008 and found Anandapala waiting on the plain of Chach with allies and Khokhar levies. For forty days, by Firishta’s account, the armies faced each other while Mahmud dug trenches. When the fighting began, thousands of Khokhars broke into the Ghaznavid camp and cut down several thousand men, and Mahmud was on the point of withdrawing. Then Anandapala’s elephant, frightened by naphtha and arrows, turned and fled, and his army took it for the king’s flight.
02After Chach
Mahmud pursued, then turned to Bhimnagar, the fort of Nagarkot in Kangra, whose temple treasury al-Utbi describes in detail. The Shahis lost the Indus line. Anandapala’s son Trilochanapala fought on at Nandana in the Salt Range and on the Tawi; he was killed in 1021, and his son Bhimapala died in 1026. The Hindu Shahi line, which had held the north-west gate for nearly two centuries, ended with them.

It was the last great stand of the Hindu Shahis; after it the Punjab lay open.
