# Turkic settlement of the Tarim Basin

Part of a series on Islam in China :
History
By dynasty
Tang
Song
Yuan
Ming
Qing
Rebellions and revolts
Jahriyya revolt
Panthay Rebellion (1856–1873)
First Dungan Revolt (1862–1877)
Second Dungan Revolt (1895–1896)
Afaqi Khoja revolts
Post-dynastic China
1912–present
Second Sino-Japanese War
Concerns and controversies at the 2022 Winter Olympics
Islamophobia
Migration to Xinjiang
Persecution of Uyghurs in China
Xinjiang internment camps :
Major figures
Afaq Khoja
Du Wenxiu
Hu Dahai
Hu Songshan
Kasim Tuet
Liu Zhi
Ma Anliang
Ma Bufang
Ma Buqing
Ma Fuxiang
Ma Gui
Ma Hualong
Ma Laichi
Ma Mingxin
Ma Qixi
Ma Wanfu
Ma Yize
Ma Zhu
Shams al-Din
Su fei-erh
Yeheidie'erding
Yusuf Ma Dexin
Wang Daiyu
Zhang Chengzhi
Zheng He :
Culture
Architecture
Cuisine (Uyghur)
Han Kitab
Mosques
Shrines
Sini script
Sufi orders
Uyghurs
Uyghur Arabic
Xiao'erjing
Islamic Association of China :
CitiesRegions
Hong Kong
Kashgar
Linxia
Macau
Ningxia
Sichuan
Xinjiang
Xunhua :
Groups
Ahmadis
Bonans
Dongxiang
Hui
Ili Turks
Kazakhs
Kyrgyz
Salar
Tajiks
Tatars
Tibetans
Utsul
Uyghurs
Uzbeks :
Islam portal • China portal :
vte :
Turkic peoples began settling in the Tarim Basin in the 7th century. The area was later settled by the Turkic Uyghurs, who founded the Qocho Kingdom there in the 9th century. The historical area of what is modern-day Xinjiang in China consisted of the distinct areas of the Tarim Basin (also known as Altishahr) and Dzungaria. The area was first populated by the Tocharians and the Saka, who were Indo-Europeans and practiced Buddhism. The Tocharian and Saka peoples came under Xiongnu and then Chinese rule during the Han dynasty as the Protectorate of the Western Regions due to wars between the Han dynasty and the Xiongnu. The First Turkic Khaganate conquered this region in 560, and in 603, after a series of civil wars, the First Turkic Khaganate was separated into the Eastern Turkic Khaganate and the Western Turkic Khaganate, with Xinjiang coming under the latter. The region then became part of the Tang dynasty as the Protectorate General to Pacify the West after the Tang campaigns against the Western Turks. The Tang dynasty withdrew its control of the region in the Protectorate General to Pacify the West and the Four Garrisons of Anxi after the An Lushan Rebellion, after which the Turkic peoples and the other native inhabitants living in the area gradually converted to Islam following the Muslim conquest of Central Asia.

## Background

The Turfan and Tarim Basins were populated by speakers of Tocharian languages and Saka languages. Different historians suggest that either the Sakas or Tokharians made up the Yuezhi people who lived in Xinjiang. During the Han dynasty, the Tocharians and Sakas of Xinjiang came under a Chinese protectorate in 60 BC, with the Chinese protecting the Tocharian and Saka city states from the nomadic Xiongnu who were based in Mongolia.
In the 6th through 8th centuries, the region was subject several incursions from the Xiongnu, Muslims, Göktürks, Tibetans, and Turkic nomads. Arab sources claim that first recorded incursion into the Tarim Basin by an Islamic force is the alleged attack on Kashgar by Qutayba ibn Muslim in 715 but some modern historians entirely dismiss this claim. The Tang dynasty Chinese defeated the Arab Umayyad invaders at the Battle of Aksu (717). The Umayyad commander Al-Yashkuri and his army fled to Tashkent after they were defeated.
Tang China lost control of Xinjiang after it was forced to withdraw its garrisons during the An Lushan Rebellion. During the rebellion China received aid from the Uyghur Khaganate in crushing An Lushan's rebels, however, multiple provocations by the Uyghurs such as selling bad quality horses to China, practicing usury when lending to Chinese, and sheltering Uyghurs who committed murder resulted in a major deterioration in relations between China and the Uyghur Khaganate. Tang China then allied with the Yenisei Kirghiz and defeated and destroyed the Uyghur Khaganate in a war, triggering the collapse of the Uyghur Khaganate which caused Uyghurs to migrate from their original lands in Mongolia southwestwards into Xinjiang.
Protected by the Taklamakan Desert from steppe nomads, elements of Tocharian culture survived until the 7th century, when the arrival of Turkic immigrants from the collapsing Uyghur Khaganate of modern-day Mongolia began to absorb the Tocharians to form the modern-day Uyghur ethnic group.

## Kara-Khanid conquest of Khotan

By the 10th century, the area was ruled by the Kingdom of Khotan and Shule Kingdom when the first Turkic began migrating into the area. The Saka Kings were still culturally-influenced by the Buddhist homeland of Northern India, with their rulers adopting Sanskrit names and titles. The rulers of Khotan grew anxious of hostilities with Turkish khanates, as evidenced by the Mogao grottoes, were they commissioned painting number of divine figures along with themselves. By the time the Uyghurs and the Kara-Khanids invaded, Khotan was the only state in the area that had not come under Turkic rule.
The Kara-Khanids formed from several Turkic groups that had increasingly settled portions of the Kashgar area. The tribes are thought to have converted to Islam following the conversion of Sultan Satuq Bughra Khan in 934. Khotan conquered Kashgar in 970, after which a long war ensued between Khotan and the Kara-Khanids. The Karakhanids fought Khotan until sometime before 1006 when the Kingdom was conquered by Yusuf Qadir Khan. The attacks likely related to Khotanese requests for aid when China. Relations with China factored heavily in the war. In 970, after the Khotanese capture of Kashgar, an elephant was sent as tribute by Khotan to Song dynasty China. After the Qara Khanid Turkic Muslims defeated the Khotanese under Yusuf Qadir Khan at or before 1006, China received a tribute mission in 1009 from the Muslims.
Following the war, a Buddhist revival occurred in the Tangut Empire, located in contemporary Western Xia, following the attacks on the Buddhist states in the region. The Empire became a safe haven for Indian Buddhist monks who were attacked and forced to flee to Tangut.

### Legacy

Many of the Muslim soldiers who died fighting the region's Buddhist kingdoms are regarded as martyrs (shehit), and are visited by pilgrims at shrines called mazar. For instance, the killing of the martyr Imam Asim led to his grave being worshiped in a massive annual ceremony called the Imam Asim Khan festival. According to Michael Dillon, the conquest of the region is still recalled in the forms of the Imam Asim Sufi shrine celebration. However, due to the ongoing persecution of Uyghurs in China, the pilgrimage has no active participants, and the mosque at the shrine has been demolished.
Taẕkirah is literature written about Sufi Muslim saints in Altishahr. Written sometime in the period from 1700 to 1849, the Eastern Turkic language (modern Uyghur) Taẕkirah of the Four Sacrificed Imams provides an account of the Muslim Kara-Khanid war against the Khotanese Buddhists. The Taẕkirah uses the story of the Four Imams as a device to frame the chronicle, the Four Imams being a group of Islamic scholars from Mada'in city (possibly in modern-day Iraq), who travelled to help the Islamic conquest of Khotan, Yarkand, and Kashgar by the Kara-Khanid leader Yusuf Qadir Khan. The legend of the conquest of Khotan is also given in the hagiology known as the Tazkirat or "Chronicles of Boghra". Extracts from the Tazkiratu'l-Bughra on the Muslim war against the Khotan was translated by Robert Barkley Shaw.
Contemporary poems and attitudes are recorded in the dictionary of the Turkic lexicographer Mahmud al-Kashgari and in the text Hudud al-'Alam. Kashgari's dictionary contains disparaging references to Buddhists. The antagonistic attitude towards Dharmic religions is striking in comparison to several earlier Islamic texts that portrayed Buddhism in a more charitable light, such as the works of Yahya ibn Khalid. Elverskog states that the attitudes in Hudud al-'Alam are dissonant, containing both accurate and libelous descriptions of Khotanese Buddhists (including a claim that the Khotanese are cannibals). He argues that these accounts were a way to dehumanize the residents of Khotan and encourage the conquest of the region.
The conquest of Khotan led to the destruction of Buddhist art, motivated by Islamic iconoclasm. The iconoclastic fervor is captured by a poem or folk song recorded in Mahmud al-Kashgari's Turkic dictionary. Robert Dankoff believes the poem refers to the Qarakhanids' conquest Khotan's despite the text's claim that it refers to an attack on the Uyghur Khaganate.

## Chagatai incursions

In the 1390s, the Chagatai ruler Khizr Khwaja launched a holy war against the Kingdom of Qocho and Turfan. Although Khizr Khwaja claimed to have converted to these kingdoms to Islam, the conversion was more gradual. Travellers passing through the area in 1420 remarked on the rich Buddhist temples, and only after 1450 were substantial numbers of mosques reported. As a consequence of the imposition of Islam, the city of Jiaohe was abandoned in the 15th century. Buddhist presence in Turfan is thought to have ended by the 15th century.
In the early 16th century, the Chagatai ruler Mansur Khan attacked Qara Del, a Mongolian-ruled and Uighur-populated Buddhist Kingdom east of Turfan, invading and forcibly converting the population to Islam. It was reported that between Khitay and Khotan the Sarigh Uyghur tribes who were "impious" resided, and they were targeted for ghazat (holy war) by Mansur Khan following 1516.

### Legacy

Following the Chagatai and Kara-Khanid invasions, many residents of the Qocho and Qara Del converted to Islam.
Residents of area previously ruled by Qocho failed to retain memory of the region's religious history and believed that the murals in the Bezeklik Thousand Buddha Caves were built by the Dzungars. Motivated by aniconism, they damaged many of the murals. Buddhist influences still remain among the Turfan Muslims.
Many in Qumul and Turfan continue to use personal names of Old Uyghur origin.