Uygur means union or alliance. Modern Uygur people can trace their ancestors back to the nomadic tribes who lived in the area of Lake Baikal and the Irtish River further north of today's Mongolia about 200 BC, contemporaneously with the Han Dynasty of the Middle Kingdom.
Among the numerous names these tribes took up was Uighur or Ouigour.
In AD 744, the Uighur founded a khanate in Mobei, an area encompassing Lake Baikal and Mongolia. They even dispatched troops twice to help the Tang central authorities to quell rebellions. However, the Uighur Khanate collapsed in 840 because of natural disasters, internal strife and attacks by neighboring tribes.
Consequently, most of the Uighur migrated westward. One of their sub-groups moved to the modern Jimsar and Turpan in Xinjiang, where they founded the Gaochang Uighur Kingdom. Another sub-group moved to the Central Asian grasslands, scattered in areas from Central Asia to Kashi, and joined other peoples in founding the Karahan Kingdom. After that, the Tarim Basin and its surrounding areas were under the rule of the Gaochang Uighur Kingdom and the Karahan Kingdom. The local residents were merged with the Uighurs that had moved west, thus laying the foundation for the subsequent formation of the Uygur ethnic group.
In the middle of the 10th century, the Uighurs founded the Hala Khanate, which had a profound influence on the development of Uighur history. During that period, Uighur farming communities began to appear and the Uygurs made rapid socio-economic and cultural progress. Prosperous trading took place in which horses, jade articles and herbs were transported inland in exchange for silk, tea and money.
From the 12th to the 13th centuries, the Uighurs in today's Xinjiang autonomous region were ruled by Western Liao and Mongol nobles. In 1209, the Gaochang regime of the Uighurs submitted to Genghis Khan and became a vassal state of the Mongol Empire. The Yuan government appointed many Uighur politicians, military leaders and scholars who later helped the Mongols defeat the Jin and Southern Song Dynasties.
In 1371, the Mongol Empire of the Chagatai Khanate collapsed and many separatist regimes were set up by descendants of the Mongols. Continuous wars greatly damaged the Uighur society and economy.
The Yarkant Kingdom was founded in the early 17th century in an area south of the Tianshan Mountain. Most of the residents of the Kingdom were Islamic Uighurs. They maintained a peaceful trading relationship with the Qing Dynasty. Tribal wars broke out in 1678 and the Baishan tribe together with the Mongol Dzungar force invaded the south, which eventually led to the demise of the Yarkant Kingdom.
From 1755 to 1759, the Qing government successfully suppressed the Dzungar and Khoja revolts. The government eventually established the military administration known as the Ili General in Huiyuan city to rule the Xinjiang region and the areas south and east of Balkhash Lake.