(1725–1738), the last ruler of the Hotak dynasty
The Khalaj in medieval Islamic period Medieval Muslim scholars, including 9th-10th century geographers
Ibn Khordadbeh and
Istakhri, narrated that the Khalaj were one of the earliest tribes to have crossed the
Amu Darya from
Central Asia and settled in parts of present-day Afghanistan, especially in the
Ghazni,
Qalati Ghilji (also known as Qalati Khalji), and
Zabulistan regions. Mid-10th-century book ''
Hudud al-'Alam'' described the Khalaj as
sheep-grazing nomads in Ghazni and the surrounding districts, who had a habit of
wandering through seasonal
pastures. 11th-century book
Tarikh Yamini, written by al-Utbi, stated that when the
Ghaznavid Emir
Sabuktigin defeated the
Hindu Shahi ruler
Jayapala in 988, the Pashtuns (Afghans) and Khalaj between
Laghman and
Peshawar, the territory he conquered, surrendered and agreed to serve him. Al-Utbi further stated that Pashtun and Khalaj tribesmen were recruited in significant numbers by the Ghaznavid Sultan
Mahmud of Ghazni (999–1030) to take part in his military conquests, including his expedition to
Tokharistan. The Khalaj later revolted against Mahmud's son Sultan
Mas'ud I of Ghazni (1030–1040), who sent a
punitive expedition to obtain their submission. During the time of the
Mongol invasion of Khwarezmia, many Khalajs and
Turkomans gathered in
Peshawar and joined the army of Saif al-Din Ighraq, who was likely a Khalaj himself. This army defeated the petty king of Ghazni, Radhi al-Mulk. The last
Khwarazmian ruler,
Jalal al-Din Mangburni, was forced by the Mongols to flee towards the
Hindu Kush. Ighraq's army, as well as many other Khalaj and other tribesmen, joined the Khwarazmian force of Jalal al-Din and inflicted a crushing defeat on the Mongols at the 1221
Battle of Parwan. However, after the victory, the Khalajs,
Turkomans, and Ghoris in the army quarreled with the Khwarazmians over the booty, and finally left, soon after which Jalal al-Din was defeated by
Genghis Khan at the
Battle of the Indus and forced to flee to India. Ighraq returned to Peshawar, but later Mongol detachments defeated the 20,000–30,000 strong Khalaj, Turkmen, and Ghori tribesmen who had abandoned Jalal al-Din. Some of these tribesmen escaped to
Multan and were recruited into the army of the
Delhi Sultanate. 13th-century
Tarikh-i Jahangushay, written by historian
Ata-Malik Juvayni, narrated that a levy comprising the "Khalaj of Ghazni" and the "Afghan" (Pashtuns) were mobilized by the Mongols to take part in a punitive expedition sent to
Merv in present-day
Turkmenistan. Founded by
Jalal ud din Firuz Khalji as the second dynasty to rule the
Delhi Sultanate of India, and successfully fending off the repeated
Mongol invasions of India.
Timurid raids One year after the 1506
Battle of Qalati Ghilji, the
Timurid ruler
Babur marched out of
Kabul with the intention to crush Ghilji Pashtuns. On the way, the Timurid army overran
Mohmand Pashtuns in
Sardeh Band, and then attacked and killed Ghilji Pashtuns in the mountains of Khwaja Ismail, setting up "a pillar of Afghan heads," as Babur wrote in his
Baburnama. Many sheep were also captured during the attack. After a hunt on the plains of
Katawaz the next day, where
deer and
wild asses were plentiful, Babur marched off to Kabul.
Hotak dynasty In April 1709,
Mirwais Hotak, who was a member of the
Hotak tribe of Ghiljis, led a successful revolution against the
Safavids and founded the
Hotak dynasty based in
Kandahar, declaring southern Afghanistan independent of Safavid rule. His son
Mahmud Hotak conquered
Iran in 1722, and the Iranian city of
Isfahan remained the dynasty's capital for six years. The dynasty ended in 1738 when its last ruler,
Hussain Hotak, was defeated by
Nader Shah Afshar at the
Battle of Kandahar.
Azad Khan Afghan Azad Khan Afghan, who played a prominent role in the power struggle in western Iran after the death of Nader Shah Afshar in 1747, belonged to the
Andar tribe of Ghiljis. Through a series of alliance with local
Kurdish and Turkish chieftains, and a policy of compromise with the
Georgian ruler
Erekle II—whose daughter he married—Azad rose to power between 1752 and 1757, controlling part of the
Azerbaijan region up to
Urmia city, northwestern and northern
Persia, and parts of southwestern
Turkmenistan and eastern
Kurdistan.
Skirmishes with British forces During the
First Anglo-Afghan War (1839–1842), Ghilji tribesmen played an important role in the Afghan victory against the British
East India Company. On 6 January 1842, as the
British Indian garrison retreated from Kabul, consisting of about 16,000 soldiers, supporting personnel, and women, a Ghilji force attacked them through the winter snows of the
Hindu Kush and systematically killed them day by day. On 12 January, as the
British regiment reached a hillock near
Gandamak, their last survivors—about 45 British soldiers and 20 officers—were killed or held captive by the Ghilji force, leaving only one British survivor, surgeon
William Brydon, to reach
Jalalabad at the end of the retreat on 13 January. This battle became a resonant event in Ghiljis' oral history and tradition, which narrates that Brydon was intentionally let to escape so that he could tell his people about the bravery of the tribesmen.
Barakzai period The Ghilji rebelled against Afghanistan's ruler in 1886, after which a large number of them were forced to migrate to northern Afghanistan by
Barakzai Emir
Abdur Rahman Khan. Among those who were exiled was
Sher Khan Nashir, chief of the
Kharoti Ghilji tribe, who would become the governor of
Qataghan-Badakhshan Province in the 1930s. Launching an industrialization and economic development campaign, he founded the Spinzar Cotton Company and helped making
Kunduz one of the wealthiest Afghan cities. Sher Khan also implemented Qezel Qala harbour on the
Panj River at the border with
Tajikistan, which was later named
Sher Khan Bandar in his honour.
Contemporary period , of the Ghilji tribe, was President of Afghanistan from 1987 to 1992 , of the Ghilji tribe, was President of Afghanistan from 2014 to 2021 More recently, the former Presidents of Afghanistan
Ashraf Ghani Ahmadzai (2014–2021) and
Mohammad Najibullah Ahmadzai (1987–1992) belonged to the
Ahmadzai branch of the Ghilji tribe. Two other former Presidents of Afghanistan,
Nur Muhammad Taraki (1978–1979) and
Hafizullah Amin (1979), belonged to the
Tarakai and
Kharoti branches of the Ghilji tribe, respectively. == Areas of settlement ==