Uyghurs
Rian Thum explored the concepts of identity among the ancestors of the modern Uyghurs in Altishahr (the native Uyghur name for eastern Turkestan or southern Xinjiang) before the adoption of the name "Uyghur" in the 1930s, referring to them by the name "Altishahri" in his article "Modular History: Identity Maintenance before Uyghur Nationalism". Thum indicated that Altishahri Turkis did have a sense that they were a distinctive group separate from the Turkic Andijanis to their west, the nomadic Turkic Kirghiz, the nomadic Mongol Qalmaq, and the Han Chinese Khitay before they became known as Uyghurs. There was no single name used by them to refer to themselves, the various native names Altishahris used to refer to themselves were Altishahrlik (Altishahr person), yerlik (local), Turki, and Musulmān (Muslim), the term Musulmān in this situation did not signify religious connotations, because the Altishahris would exclude other Muslim peoples like the Kirghiz when referring to themselves as Musulmān. Dr. Laura J Newby has also noted that the sedentary Altishahri Turkic people felt themselves as a separate group from other Turkic Muslims since at least the 19th century.
Uyghurs
The 12th and 13th century saw the domination by non-Muslim powers: first the Kara-Khitans in the 12th century, followed by the Mongols in the 13th century. After the death of Genghis Khan in 1227, Transoxiana and Kashgar became the domain of his second son, Chagatai Khan. The Chagatai Khanate split into two in the 1340s, and the area of the Chagatai Khanate where the modern Uyghurs live became part of Moghulistan, which meant "land of the Mongols". In the 14th century, a Chagatayid khan Tughluq Temür converted to Islam. His son Khizr Khoja conquered Qocho and Turfan (the core of Uyghuristan) in the 1390s, and the Uyghurs there became largely Muslim by the beginning of the 16th century. After being converted to Islam, the descendants of the previously Buddhist Uyghurs in Turfan failed to retain memory of their ancestral legacy and falsely believed that the "infidel Kalmuks" (Dzungars) were the ones who built Buddhist structures in their area.