The Gurjara-Pratihara was a dynasty that ruled much of Northern India from the mid-8th to the 11th century. They ruled first at Ujjain and later at Kannauj. The Gurjara-Pratiharas were instrumental in containing Arab armies moving east of the Indus River. Nagabhata I defeated the Arab army under Junaid and Tamin in the Caliphate campaigns in India. Under Nagabhata II, the Gurjara-Pratiharas became the most powerful dynasty in northern India. He was succeeded by his son Ramabhadra, who ruled briefly before being succeeded by his son, Mihira Bhoja. Under Bhoja and his successor Mahendrapala I, the Gurjara-Pratihara dynasty reached its peak of prosperity and power. By the time of Mahendrapala, the extent of its territory rivalled that of the Gupta Empire stretching from the border of Sindh in the west to Bengal in the east and from the Himalayas in the north to areas past the Narmada in the south. The expansion triggered a tripartite power struggle with the Rashtrakuta and Pala empires for control of the Indian subcontinent. During this period, Imperial Pratihara took the title of Maharajadhiraja of Āryāvarta (Great King of Kings of Aryan Lands). Gurjara-Pratihara are known for their sculptures, carved panels and open pavilion style temples. The greatest development of their style of temple building was at Khajuraho, now a UNESCO World Heritage Site. The power of the Gurjara-Pratihara dynasty was weakened by dynastic strife. It was further diminished as a result of a great raid led by the Rashtrakuta ruler Indra III who, in about 916, sacked Kannauj. Under a succession of rather obscure rulers, the dynasty never regained its former influence. Their feudatories became more and more powerful, one by one throwing off their allegiance until, by the end of the tenth century, the dynasty controlled little more than the Gangetic Doab. Their last important king, Rajyapala, was driven from Kannauj by Mahmud of Ghazni in 1018. Etymology and origin The origin of the dynasty and the meaning of the term "Gurjara" in its name is a topic of debate among historians. The rulers of this dynasty used the self-designation "Pratihara" for their clan, and never referred to themselves as Gurjaras. They claimed descent from the legendary hero Lakshmana, who is said to have acted as a pratihara ("door-keeper") for his brother Rama. Some modern scholars theorize that a Pratihara ancestor served as a "minister of defense" (or Pratihara) in a Rasthrakuta court,