Political History of the Kara-Khanid Khanate: From its Origins to the Division of the Empire  

The Karakhanids and Ghaznavids partitioned the Samanid territory in 1017. Mahmud of Ghazni is depicted riding his elephant, while the Karakhanid prince is on horseback. This miniature painting is from a manuscript of Rashid al-Din’s Jami’ al-Tawarikh, c. 1306-1314 CE.

The migrating Karakhanids arrived at the borders of the Islamic world around the middle of the 9th century. To their west, the Samanid emirs of Bukhara held sway over a vast territory. The Karakhanids settled around the city of Kashgar, currently one of the westernmost cities in China. They established an independent khanate, which — despite many challenges including rampant dynastic factionalism — would last into the early 13th century. At the height of their power, the Karakhanids ruled an empire which stretched from the Tarim Basin in the east to the Oxus River (Amu Darya) in the west. In this article we shall discuss the political history of the khanate up until its division around 1040.

The early history of the Karakhanids is clouded in mystery, as the relevant sources tend to contradict each other. The Karakhanid confederacy consisted of many different nomadic tribes. When exactly this confederacy was formed is a matter of controversy. Some date the event right after the dissolution of the Türgesh empire in 744, while others situate the rise of the confederacy right after the fall of the Uyghur Khanate in 840. Omeljan Pritsak believes that the khanate was in its origins a continuation of the earlier Karluk Khanate. In any case, many tribes joined the ranks of the confederacy, such as the Yagma, Karluks, and the Chigils. Some historians believe the first ruler of the Karakhanids to be a certain Bilge Kul Qadir Khan. He is at least the first attested Karakhanid ruler. E. Davidovich claims that the rulers of the khanate themselves were either of Yagma or Chigil blood.

The nomad warriors settled at the border with the Samanid Emirate and chose Kashgar as their centre of power. Brushes with the Samanids might have already occurred during this early period, with the emirs of Bukhara even reinforcing Isfijab, the modern-day Kazakh city of Sayram, around 840 to protect its crops against nomads, possibly the Karakhanids. Later in 893, the Samanid ruler Ismail Samani took Talas, current Taraz in Kazakhstan, possibly out of the clutches of the nascent Turkic confederacy. Talas was an important commercial hub and concurrently an important historic site, as the Chinese armies of the Tang dynasty had halted the seemingly unstoppable advance of the Abbasid caliphate here some 150 years prior. The relationship between the emirate and the khanate was not only characterized by armed conflict, however, as interregional trade continued to flourish.

Karakhanid history starts to become clearer by the time of the mass conversion to Islam around 950 CE. It was Bughra Qara Khāqān Satuq (r. 942–955/60), the son or nephew of the ruler, who first embraced Islam in Artuj, a village not so far from Kashgar. Satuq then revolted against his overlord, conquered Kashgar, and continued to defend his newfound faith. This prompted many more Turks, traditionally held at “200,000 tents”, to follow suit and accept Islam.

By the reign of Satuq, Karakhanid power had spread into the Ferghana Valley and Zhetsyu. Control over the Ferghana Valley gave the Karakhanids enormous power. Through this fertile valley, in fact, ran one of the main arteries of the Silk Road, along the Jaxartes River, cushioned between the slopes of the Tian Shan and the Alay Mountain Range. To the north of the Ferghana Valley is Zhetsyu, also known as Semirechye, situated in the southeast of modern-day Kazakhstan and the north of Kyrgyzstan. Its name comes from the Kazakh for “Seven Rivers”. The region is bordered to the north by Lake Balkhash and to the south by the Tian Shan.

The conversion to Islam deeply influenced the state apparatus, as honorifics from the Islamic world started pouring into the territory of the Karakhanids and became fixed titles in the hierarchy of the empire. It is worthy of note that the khans kept the Turkish names of the highest positions in the khanate, probably with the desire to maintain Turkic culture as the culture of power. This didn’t withhold the khans from simultaneously adopting Arab titles such as sultan.

Further expansion

Kara-Khanid Khanate, c. 1000.


The khanate’s expansion was predominantly oriented toward the west, as the rulers had set their sights on the wealthy lands of the waning Samanid Empire. There were nonetheless also military operations worthy of note which were directed elsewhere. During the last third of the 10th century, for example, the warriors of the khan campaigned against the rich city-states of Yarkand and Khotan, both situated along the southern caravan route of the Tarim Basin. Especially the wealthy oasis city of Khotan was an attractive target. The war with this polity started at the latest in 971 and was completed around 1000 CE. Satuq had traditionally been named the conqueror of Khotan, but Jürgen Paul identifies Yusuf Qadir Khan as the likelier victor of this city-state. Besides these expeditions, the Karakhanids for the rest did not venture further to the east, leaving their Uyghur neighbours in peace.

The Karakhanids’ military ambitions were dominated, however, by a desire to expand westward, where wealthy Transoxiana was gradually slipping out of Samanid control. The ruler, Arslan Qara Khāqān Ali ibn Musa, and his cousin, the Bughra Qara Khāqān, Hasan ibn Sulayman, initiated these campaigns against their once so powerful neighbours. Omeljan Pritsak and most of the other historians refer to their two respective branches of the dynasty as the Alids and the Hasanids, which played a pivotal role in the decades to come. Bughra Qara Khāqān Hasan started the conquest in 990, taking the already mentioned city of Isfijab and the rest of Ferghana. He then went on to capture Samarkand and the Samanid capital, Bukhara, in 992. The Bughra Qara Khāqān celebrated these astonishing achievements by minting his own coins. Hasan ibn Sulayman wasn’t able to relish his triumph for too long, as he fell ill during his stay in the Samanid capital. On his way home to Kashgar, the Bughra Qara Khāqān died. His recent conquests, unconsolidated, slipped out of Karakhanid control.

It was then the turn of the Alids to try and expand the empire. The ruler’s son, Arslan Ilek Nasr ibn Ali, was appointed to lead the Karakhanid troops back into Transoxiana. During this invasion of the Samanid emirate between 996 and 999, the Turkic nomads acted in coordination with the nascent Turkic Ghaznavids. The emirs of Bukhara stood no chance against this onslaught, and thus the proud Samanid empire fell by the sword of the Turks. Transoxiana was allocated to the authority of the Karakhanids, while Khorasan fell under the yoke of the Ghaznavids. Samarkand and Bukhara once again had to endure the presence of imposing Turkic cavalrymen marching through their streets. This time, the wealthy region between the Oxus and Jaxartes would not slip out of Karakhanid control again. They were here to stay.

Although the military might of the Karakhanids should certainly not be downplayed, the fact that the Samanid emirate was in the twilight of its existence certainly facilitated the conquest of Transoxiana. The Samanid empire was at the time being torn apart by factionalism and separatist lords in the provinces. It was in this context that, for example, the Ghaznavid dynasty emerged, which would play a pivotal role in Central Asian and Iranian history in the century to come. Moreover, when the Turkic warriors arrived from the east, several high-profile figures and major landowners (dihqān) were eager to throw in their lot with the Karakhanids, fuelled in their decision by their frustration over the current state of affairs. Their newly pledged loyalty to these Turkic nomads was certainly facilitated by the fact that the Karakhanids were orthodox Hanafite Sunni Muslims and had sworn allegiance to the Abbasid caliph, an allegiance celebrated and replicated by the majority of the Muslims in Transoxiana. The Karakhanids handsomely rewarded those who rallied to their cause. Begtuzun, an important official of the Samanid state, for example, defected to the Karakhanids and was subsequently given important commands, such as the governorship of the city of Kish. The loyal dihqāns’ position was also strengthened under Karakhanid rule as a token of gratitude on the khan’s part.

After the conquest of Transoxiana, the Karakhanids’ lust for power drove them further westward, this time putting Khorasan on their wish list. They marched two times against their former allies in 1006 and 1008, but both attempts were successfully thwarted by the Ghaznavids. The Oxus River therefore became the accepted border between the two Turkic empires. This meant that for the first time in Islamic history, Khorasan and Transoxiana were controlled by two different states. Transoxiana consequently became more and more entangled and connected with the regions of Zhetsyu (Semirechye) and the Tarim Basin, while Khorasan became more enveloped in the Persian world.

Political organisation and army of the Karakhanids 

The period up until c. 1040 is considered the flourishing period of the unified khanate. The state reached its classical form, dominated by a dual structure like the Turkic Khaganates of before. This meant there were two khāqāns (meaning “supreme ruler”), ruling from two capitals: Balasagun (later Samarkand) in the west and Kashgar in the east. The eastern khāqān of Kashgar had ascendancy over the other, however, adding the totemic animal Arslan (lion) to his title. All the coins minted within the empire duly referred to him as suzerain. Below the Arslan Qara Khāqān stood the Bughra (“male camel”) Qara Khāqān, ruling in the west. Below the rulers were the princes who were given various regions as appanages. These princes were referred to as ilak-ilig or tegin, which was then also combined with the Turkish word for a totemic animal. Kochnev claimed, after a study, that there was no clear hierarchy in these different dynastic titles of the princes. The rest of society, however, was governed by a strict hierarchy in which various Turkic and Arabic titles meticulously indicated each person’s position.

Prince on his throne, with standing courtiers, Afrasiyab, Samarkand, dated 1170–1220 CE. National History Museum of Samarkand.

The key to the Karakhanids’ success was their feared army, which the famed Arab historian and scholar, Ibn al-Athir (1160–1232/33), described in his work. Al-Athir informs us that the members of the Chigil tribe formed the bulk of the western Karakhanid army in the late 11th century. Most of the warriors were probably mounted nomad archers. Professor Dr. Reşat Genç claims that the army’s units were organised according to the decimal system. Military slaves (ghilman) are mentioned but rarely in large numbers. They were used for various assignments. Nasr ibn Ali, for example, used his ghilman during his attack against Khorasan. Altegin left his ghilman behind in Bukhara as guards while he went campaigning. These contingents of military slaves could sometimes swell up to extraordinary numbers, however. Bundari, the famed translator of the Shahnameh into Arabic, for example, reported in his Zubdat al-nusra wa nukhbat al-usra that the ruler of Samarkand had 12,000 Turkish slave soldiers at his disposition. This number, although probably a gross exaggeration, is indicative of the size these ghilman detachments could sometimes attain. The Karakhanid army maintained a nomadic lifestyle, with the generals laying up camp far from urban centres. This probably has to be understood as a disciplinary measure, as well as culturally motivated. As stated in the previous article on the Karakhanids, the khāqāns tried to maintain their Turkic ancestral nomadic customs.

The falling apart of the Karakhanid family 

After the death of Ali ibn Musa in 998, two of his sons, first Ahmad and then Mansur, subsequently took over the reins of the empire as Arslan Qara Khāqān. No references to Ahmad have been discovered in the written sources. Nasir al-Haqq Khan is found more often on coinage and seemed to be one of the most powerful figures in the empire at that time. He was the appanage-holder of Semirechye and Chach, with the ancient Sogdian city of Balasagun as the centre of his territory. It appears that Balasagun simultaneously practically served as the capital of the whole khanate for a period.

Another extremely powerful figure at the time was the brother of the ruler, Nasr ibn Ali, the conqueror of Transoxiana who was subsequently given this region as appanage together with Ferghana. Nasr ruled from Uzgend, also known back then as Mavarannahr (modern-day Özgön/Uzgen). The Karakhanid past in the city is beautifully preserved through some exquisite mausoleums. Although Nasr’s rule was absolute in his appanage, he never took up arms against his brother and recognized his suzerainty on his coins. Over time, however, cracks started to appear on the surface, illustrated, for example, by dissent regarding foreign policy. At a certain point, Nasr and Ahmad pursued different goals vis-à-vis their Ghaznavid neighbours. Whereas Nasr was eager to expand his borders southward, Ahmad wished to maintain friendship with the mighty sultan Mahmud of Ghazni (r. 998–1030).

The unrest within the dynasty increased after the death of Nasr. Ahmad’s brother, Bughra Qara Khāqān Mansur, started expressing his dissatisfaction over his second place in the hierarchy of the empire. Mansur defiantly assumed the title Arslan Qara Khāqān at his capital of Balasagun, basically declaring himself the new head of the family. A conflict ensued which threatened to tear the khanate apart, had the shah of Khwarazm, Ma’mun, not intervened. What followed was an uneasy peace during which Ahmad, Mansur, and Yusuf ibn Hasan of the Hasanids all clung to the title Arslan Qara Khāqān.

After this civil war, tensions with the neighbouring Turkic nomads to the east came to a head. Campaigns were organised by Ahmad against these non-Muslim Turks to the northeast and east. Ahmad’s war with these “infidel” Turks earned him recognition throughout the Muslim world, as he was bestowed the honorific title of ghazi, i.e., fighter of the faith, as evidenced by a coin studied by Kochnev. Despite his perceived heroic defence of the Islamic faith, the troubles with the Turkic nomads did not end here. Later, Turkic invaders almost reached Balasagun, but luckily for the Karakhanids, many Muslim warriors rallied to their banner and repelled the “infidels”. The victory was widely celebrated throughout the Muslim world.

The Hasanids come to the fore 

Around 1017/18, Arslan Qara Khāqān Ahmad ibn Ali passed away, and authority over the whole family finally unambiguously passed on to his brother Mansur. When Mansur later died around 1024/25, it was the turn of the Hasanid branch of the Karakhanid dynasty to dictate the future course of the empire. It was Muhammad Toghan Khan II, son of Hasan ibn Sulayman, who ascended the Karakhanid throne as the first Hasanid, although he ruled only briefly. He died in 1026 and was succeeded by his rival brother Yusuf Qadir Khan, ruler of Kashgar. The first two Hasanids are overshadowed, however, in the annals of history by the success and power of their brother, Ali Tegin.

Dirham of Ali Tegin. Classical Numismatic Group

Ali Tegin was a central figure in Transoxiana at the time. Before the Hasanids’ ascendancy, he was briefly imprisoned at Bukhara by Mansur, but escaped with the help of a warband of Oghuz Turks, led by the Seljuq, Arslan Isra’il. Ali Tegin later married off his daughter to Arslan Isra’il out of gratitude for his past services. Arslan Isra’il, in fact, also helped Ali Tegin lay hold of his previous prison, the rich city of Bukhara, and afterwards the rest of Transoxiana. The wealth of the region soon started flowing into the pockets of Ali Tegin, much to the jealousy of Yusuf Qadir Khan, looking on from his eastern capital of Kashgar.

Ali Tegin then sided with his brother Muhammad against their overambitious and jealous sibling in Kashgar. When Yusuf Qadir Khan became the head of the empire, Ali Tegin carried on doing as he pleased in Transoxiana, further expanding his authority in the region. Transoxiana remained under his firm control, and his power seriously worried his neighbours. Sultan Mahmud of Ghazni and Yusuf Qadir Khan struck an alliance to oust Ali Tegin from Transoxiana. The subsequent attack on Ali Tegin’s possessions in 1025 was short and fierce. Despite the military success of the two Turkic allies, the sudden retreat by Mahmud’s forces allowed Ali Tegin to return to his throne, probably much to the frustration of Yusuf Qadir Khan. Mahmud was more than pleased, however, with the campaign’s outcome, as now both Karakhanid rulers were left in too weak a state to actually pose a serious threat to his sultanate.

Ali Tegin, meanwhile, remained firmly in control and passed on the rule of Transoxiana to his sons. Torn apart by these civil wars, the unified khanate was in its twilight. Factionalism had become inherent to the empire, and its permanent division had only become a matter of time. This is, however, a subject for another day. 

Olivier Goossens

Sources:

-Biran, M., “Ilak-Khanids”, Encyclopedia Iranica, 2012.

-Davidovich, E., “The Karakhanids”, UNESCO, 1996. Consulted on 9 April 2025 through https://en.unesco.org/silkroad/sites/default/files/knowledge-bank-article/vol_IVa%20silk%20road_the%20karakhanids.pdf.

-Genç, R., Karahanlı Devlet Teşkilatı, 2002. 

-Golden, P., “The Karakhanids and Early Islam”, The Cambridge History of Early Inner Asia, ed. D Sinor, 1994, Cambridge, pp. 343-370.

-Paul, J., “The Karakhanids”, El-Three, Vol. 3, 2021, pp. 57-69.

-Pritsak, O., “Die Karachaniden”, Der Islam, Vol. 31, 1953, pp. 17-68.

-Starr, F., Lost Enlightenment: Central Asia’s Golden Age from the Arab Conquest to Tamerlane, 2013, Princeton. 

-Theobald, U., “The Qaraqan Empires 黑汗 (Karakhans)”, ChinaKnowledge.de. Consulted on 9 April 2025 through http://www.chinaknowledge.de/History/Altera/qaraqans.html

Leave a comment

Blog at WordPress.com.

Up ↑