Frontiers of the Tang and Song Empires
A digital map project
This page includes fourteen digital maps on the frontiers and borders of the Chinese empires of Tang (618-907) and Song (960-1276). Unlike traditional printed maps and digitally-produced static maps, these maps allow users to zoom in and view topographical features via satellite imagery. They also allow us to relate the locations involved to modern toponyms and national boundaries. (Note, however, that the satellite imagery does not depict rivers as clearly as traditional maps, and that some coastlines have changed over time.) My commentary on the maps also seeks to correct some prevalent misconceptions and myths relating to Tang frontiers - most of which I once took for granted myself.
I welcome comments, suggestions, and corrections via e-mail at yangs@denison.edu .
The Tang empire
Tang cavalrymen in the Tarim Basin. (Image generated using DALL-E 3)
Map 1: Kucha, 648-649
Map 1
Most conventional narratives of Tang history, including the authoritative Cambridge History of China, identify the Tang invasion of the kingdom of Kucha (1) in 648-649 as marking Emperor Taizong's conquest of the Tarim Basin . This "guided tour" map will explain why the conventional interpretation is flawed and the Tang conquest of the Tarim Basin should instead be dated to ten years later - that is, ten years after Taizong's death in 649.
The official reason given by the Tang for invading Kucha was that after its king Suvarnadeva's death in 647, his brother Haripushpa succeeded him and broke Kucha's ties of vassalage to the Tang by attacking neighboring states. The Tang intended to remove Haripushpa from his throne and replace him with a pro-Tang member of the royal family.
In reality, Kucha's relations with the Tang had already soured during Suvarnadeva's reign, after he stopped sending tribute to Taizong and aligned himself more firmly with one faction of the divided Western Turk khaganate (2).
In 644, the Tang had already invaded Kucha's neighbor to the east, Agni (Yanqi, Karashahr, 3), to wrest it away from the Western Turk sphere of influence. The Tang expedition captured the king of Agni and replaced him with a pro-Tang relative, but the Western Turks simply replaced the pro-Tang client ruler with their own candidate once the Tang army left.
Suvarnadeva reportedly contemplated sending a Kuchean army to aid Agni during the Tang invasion, but did not do so in the end. He did, however, assume responsibility for executing the pro-Tang puppet king of Agni after the Western Turks handed him over to Kucha, thus signalling a complete break with the Tang empire.
In 648, the Tang expedition against Kucha was commanded by three generals: the Eastern Turk aristocrat Ashina Zhanir (She'er) , the Tiele (Tegreg) chieftain Kibir Garek (Qibi Heli) , and the Chinese Guo Xiaoke. Guo was Protector General of the Anxi (Pacified West) Protectorate , established at Turfan (4) after its conquest by the Tang in 640.
The expeditionary forces reportedly consisted of 100,000 Turkic cavalry supplied by the Eastern Turks of Inner Mongolia and the Tiele (Tegreg) tribes of Mongolia, who had become vassals of the Tang in 630. Taizong also called on the Tuyuhun khaganate and the rising Tibetan empire to contribute contingents of troops, but it is unlikely that they did.
In late September of 648, the Tang expedition took an unconventional route to Kucha by advancing from Turfan into the Tianshan Mountains (5) and defeating the Turkic tribes of Chigil (Chuyue) and Chömül (Chumi). The Tang troops then crossed south into the Tarim Basin, bypassing Agni and attacking Kucha from the north. The expedition fanned out into five columns to dominate the area surrounding Kucha.
Upon hearing of the Tang invasion, the king of Agni (3) fled his capital city and headed toward Kucha for safety. But he was captured by one of the Tang columns and put to death; the Tang later installed one of his cousins in his place.
Many of Kucha's cities fell in short order, as their garrisons also panicked and fled.
A Kuchean army of some 50,000, led by Haripushpa and his chief ministers Nāri and Kereptaññe, marched out from the kingdom's capital to engage the Tang expedition in battle (6). The Tang vanguard, one thousand-odd Turkic cavalry commanded by Han Wei, feigned a retreat and lured the Kucheans into the path of a second Tang force led by Cao Jishu. Caught by surprise, the Kucheans routed and retreated into the city.
As the Tang army closed in to attack the Kuchean capital (7), Haripushpa fled westwards on horseback, accompanied by Nāri, Kereptaññe, and some bodyguards. The Tang officers Su Haizheng and Xue Wanbei pursued him with a detachment of elite Turkic cavalry. Meanwhile, the Kuchean capital surrendered and Guo Xiaoke was assigned to guard it with a thousand troops while most of the Tang expedition moved on to conquer the rest of the Kucha kingdom.
Haripushpa, fearful of being overtaken by the Tang cavalry, took refuge in the city of Bharuka (Bohuan = Aksu, 8). On January 19, 649, the city fell after a siege of forty days. Haripushpa and Kereptaññe were taken prisoner, but Nāri escaped and rallied more than 10,000 Kuchean troops, as well as Western Turk reinforcements, for a counterattack on the capital.
Guo Xiaoke was encamped outside the capital and received warnings from Kuchean informants that an enemy force was approaching. He ignored these warnings, assuming them to be a ruse to make him abandon the city.
When the Kuchean counterattack did arrive, Guo realized that he was outnumbered ten to one. He tried to retreat within the city walls, but the Kuchean attackers were already scaling the walls, while the Kucheans within the walls also turned on their Tang occupiers. Showered with arrows from both within the city and without, Guo Xiaoke tried to fight his way out but was killed at the city's western gate.
Other Tang troops under Han Wei and Cao Jishu soon arrived and attacked the city from its northwestern corner. Nāri, realizing that the city could not hold out, retreated the next morning. The Tang forces reentered the city and beheaded over three thousand inhabitants who had joined the resistance.
More than ten days later, Nāri returned with another 10,000 Kuchean troops from the kingdom's northern Tianshan frontier. This time, Cao Jishu defeated them, killing more than 8,000. Nāri fled the battlefield but was betrayed by his countrymen and handed over to the Tang forces.
The Tang expedition captured five major cities and more than seven hundred towns and took tens of thousands of Kuchean prisoners. After installing Haripushpa's younger brother as king and inscribing a stone stele to commemorate its victory, the expeditionary force returned to Turfan with Haripushpa and Nāri in its custody.
In late February 649, Haripushpa and Nāri arrived in Chang'an (12) and were presented to Taizong to await judgment. Taizong berated them for their "disloyalty" and then detained Haripushpa in Chang'an, appointing him to a sinecure in the imperial guards.
In August, the king of Khotan (13) also arrived in Chang'an to pay homage to the newly enthroned Gaozong, Taizong having died in the summer. Toward the end of the Kucha expedition, Xue Wanbei had been sent to Khotan on a mission to intimidate its king into pledging allegiance to the Tang; presumably, the alternative would have been an invasion like that which Kucha had just suffered.
Like the Agni expedition of 644, the Kucha expedition was a limited "regime change" raid that proved ineffective in the long run.
Many modern historical accounts claim, however, that the expedition resulted in a conquest of the Tarim Basin, with Tang military garrisons established in the capital cities of Agni, Kucha, Khotan, and Shulik (Shule, Kashgar=Kashi) as the "Four Garrisons of Anxi" and the Anxi Protectorate headquarters moving from Turfan to Kucha.
This is a misconception rooted in a number of inaccurate Chinese sources linking the 648 expedition to the establishment of the Four Garrisons. As the Chinese historian Zhang Guangda has shown, excavated texts from the Astana cemetery in Turfan (14) prove that the Tang did not move the headquarters of the Anxi Protectorate to Kucha at this time.
Tang records state that "after the Tang troops left, [Kucha's] chieftains fought among themselves to seize the throne." In other words, Haripushpa's younger brother proved ineffectual and unpopular as king, and the kingdom descended into civil war. This would hardly have happened if a Tang military force was present in Kucha to back up the new king's authority.
In September 650, therefore, Gaozong reappointed Haripushpa as king of Kucha and released him to return and rule his people.
Instead of stationing garrisons in the Tarim Basin, Taizong's strategy for breaking the Western Turks' hold over the oasis states of that region was to support a pro-Tang Western Turk chieftain, Ashina Garo (Helu) , and appoint him as the Area Commander of Yaochi. Garo's task was to attack other Western Turk factions from his base at Bagha (Mohe) fort (modern Fukang, 16).
Taizong's strategy backfired soon after his death, as Ashina Garo moved west into the Western Turk heartland (17), conquered the other Western Turk factions, and declared himself an independent khagan in 651. Now holding the title Ishbara Khagan, he soon extended his influence into the Tarim Basin and Tianshan regions and began raiding the Tang frontiers.
Meanwhile, Haripushpa's rule in Kucha had descended into another crisis. The king had fallen out with his minister Nāri over an affair that the latter was carrying on with the queen (a Western Turk woman from the Ashina aristocracy). Each man accused the other to the Tang court, upon which Gaozong summoned them both to Chang'an and imprisoned Nāri.
By the time Haripushpa returned to Kucha, Kereptaññe had seized power in the capital and aligned Kucha with Ishbara Khagan (again, this would hardly have been possible with a Tang garrison present!). Haripushpa took refuge in another city and died of an illness while awaiting aid from the Tang.
In early 658 a Tang army under the command of Su Dingfang , strengthened by a large contingent of Uyghur cavalry from the Mongolian steppe, invaded Ishbara's khaganate and inflicted a decisive defeat on him at the Irtysh River (19).
Ishbara fled southwest to Tashkent (Chach , 20) but was betrayed and handed over to the Tang. He was taken to Chang'an and pardoned for his "crime" of rebelling against Tang suzerainty, but remained a prisoner until his death in 659.
In the immediate aftermath of Ishbara's defeat, a Tang army commanded by Yang Zhou marched on Kucha and defeated the army of Kereptaññe, capturing him and his pro-Turk followers and massacring them all. Yang Zhou then installed Haripushpa's son as king.
That summer, the Tang court moved the Anxi Protectorate from Turfan to Kucha for the first time and deployed a permanent Tang garrison to the Kuchean capital to prevent pro-Turk factions from emerging again.
But the Tang still did not have control over the entire Tarim Basin. One of Ashina Helu's Western Turk followers, a chieftain named Duman, was aligned with the west Tarim kingdoms of Shulik (Kashgar/Kashi) and Chugupan (Zhujubo= Kargilik , 22) and the Pamir Mountains kingdom of Khabandha (Yebantuo= Tashkurgan ) and led them in a successful invasion of Khotan (13) in 659.
In the winter of 659, a Tang army (again under Su Dingfang) defeated Duman and besieged him in a city, upon which he surrendered.
Since the Tang did not have firm control over Kucha until 658 and did not have any control over Shulik/Kashgar and Khotan until late 659, it is most likely that the Four Garrisons of Anxi did not exist until late 659 or 660. But, as we shall see in Map 3, this military occupation of the Tarim Basin would prove very short-lived.
- The reconstruction of the Kuchean names of Haripushpa's ministers as Nāri and Kereptaññe (from the Chinese transliterations 那利 and 羯獵顛) was first proposed in 2012 by the Taiwanese scholar Ching Chao-jung and the Japanese scholar Ogihara Hirotoshi, on the basis of excavated Kuchean documents. Ching also argues that Nāri and Kereptaññe were not given names but rather clan names, and that these were the two most powerful clans in Kucha's aristocracy. Ching's analysis has now been published as Ching Chao-jung (Qing Zhaorong) 庆昭蓉, Tuhuoluo yu shisu wenxian yu gudai Qiuci lishi 吐火罗语世俗文献与古代龟兹历史 (Beijing Daxue Chubanshe, 2017).
- For Zhang Guangda's argument that the Anxi Protectorate moved to Kucha in 658, not 648, see Zhang Guangda 張廣達, Xiyu shidi conggao chubian 西域史地叢稿初編 (Shanghai Guji Chubanshe, 1995), 144-147.
Ruins of a Buddhist stupa at Subashi , near Kucha/Kuqa
Map 2: Goguryeo, 645
Map 2 depicts the first Tang invasion of Goguryeo in 645, which failed due to the strong defense system of mountain fortresses (sanseong) on the Liaodong peninsula. The ruins of many of these stone-walled fortresses can still be seen today; click on the links in the map markers to see photographs of some of these.
Map 2
- Note that I have given the Chinese pronunciations of fortress names, followed by the Korean versions in parentheses. In some cases, the name clearly has a Chinese origin or is a Chinese translation from its Korean form.
Taizong's pretext for invading Goguryeo was to punish its minister Yeon Gaesomun for assassinating the king and seizing power in 642, as well as ending Goguryeo's aggressive warfare against its neighbor to the south, Silla. But Taizong's real motivation was most likely to prove himself capable of accomplishing what the Sui dynasty had failed to do : that is, conquer Goguryeo and thus restore the territories of Liaodong and Pyongyang to the Chinese empire. The futile Sui campaigns against Goguryeo had placed intolerable burdens of taxation and conscription on the people and triggered the wave of revolts that destroyed the Sui empire. Taizong's ministers were apprehensive that history might repeat himself, but Taizong was confident in his skills as a leader and military commander, and insisted on directing the invasion of Goguryeo in person.
The dark blue arrows indicate the route of an advance ground force of 60,000 troops commanded by Li Shiji and Li Daozong . After crossing the Liao River on May 1, the advance force menaced the fortress of Xincheng (Shinseong) and then bypassed it to capture the nearby fortress of Gaimou (Gaemo) on May 26. It later rendezvoused at Liaodong (Yodong) fortress with the main invasion force (red arrows) personally commanded by Taizong.
After merging in early June, the main force and advance force besieged and captured Liaodong and Baiyan (Baegam) before defeating a large Goguryeo army (reportedly 150,000 strong) outside Anshi (Ansi) in July.
Walls of Yanzhoucheng , the former fortress of Baiyan
The light blue arrow indicates another smaller ground force of Kitan and Qay auxiliaries, commanded by Zhang Jian, that raided Jian'an (Geonan) fortress early in the campaign, killing several thousand Goguryeo troops.
The black arrows indicate a seaborne invasion force of 500 ships and 43,000 troops (40,000 from south China and 3,000 from Chang'an and Luoyang) that sailed to the southern tip of the Liaodong peninsula from Laizhou, Shandong. This force, commanded by Zhang Liang , captured Beisha (Bisa) fortress on June 1 and then moved north (probably by sea again) to threaten Jian'an.
The fortresses of Jian'an and Xincheng continued holding out. Taizong considered using the main force to attack Jian'an rather than Anshi, believing it to be a far easier target. Li Shiji dissuaded him from this plan, fearing that the Anshi garrison would cut the Tang army's supply lines between Liaodong and Jian'an.
Two captured Goguryeo generals also advised Taizong to bypass Anshi and head straight for Wugu (Ogol) [see red dotted arrow], the fall of which would open up the route to the Goguryeo capital at Pyongyang. Zhangsun Wuji persuaded Taizong to reject this plan, reasoning that the Goguryeo garrisons in Jian'an, Anshi, and Xincheng could cut the invasion force off if it advanced without eliminating them first.
The Tang siege of Anshi , which began in mid-July and lasted for three months, failed despite intense attacks on the walls using trebuchets, rams, and a siege mound. When the defenders jeered at Taizong, he became enraged and vowed to massacre them all when the city fell - a big mistake, apparently, as it further stiffened the defenders' resolve to hold out.
- The siege of Anshi was recently dramatized and fictionalized in the South Korean film "The Great Battle" (Korean title: "Ansi-seong"). The film depicts the commanding general of Anshi shooting an arrow into Taizong's eye. This is a fixture of Korean accounts of the siege, but seems to be a Korean myth first attested in the fourteenth century: see Tineke D'Haeseleer, "Tang Taizong in Korea: The Siege of Ansi," East Asian History 40 (2016).
In mid-October, Taizong decided to lift the siege of Anshi and retreat from Liaodong, abandoning his newly established prefectures in Gaimou, Liaodong, and Baiyan, because winter was coming and his army was running out of supplies.
Humiliated by his first unequivocal military failure, Taizong planned a second invasion that would deploy 300,000 troops, but died in 649 before he could carry it out.
Goguryeo repelled all Tang attempts at conquest for another twenty years, even after the Tang opened a second front to its south in 660 by conquering Baekje in coordination with Silla.
The Liaodong defense system finally failed in 666-668, due to discord within the Yeon family after the death of Yeon Gaesomun. One of Gaesomun's sons defected to the Tang and helped Tang forces to break through the line of Liaodong fortresses, starting with Xincheng and moving north to neutralize the fortresses around Buyeo (Fuyu; see map above) before driving south to the Yalu River and on to Pyongyang.
The Goguryeo leadership surrendered in 668, but an anti-Tang resistance movement soon emerged and received aid from the Tang's erstwhile ally, Silla, which also began attacking Tang occupation forces in the former Baekje.
Map 3
Map 3: The Tang empire, 669
Map 3 depicts the Tang empire at the height of its expansion in 669.
Taizong, who is today renowned (but probably overrated) as a conqueror, captured most of the Eastern Turk elite as their empire collapsed from internal revolts in 627-630; broke the strength of the Tuygun (Tuyuhun) khaganate of Kokonor with an invasion in 635; conquered the pro-Turk city-state of Gaochang (Turfan/Turpan) in 640; and secured the eastern Turkic peoples' recognition as their Khagan in 630 and/or 646. As we have seen in Map 1, however, he did not succeed in establishing lasting control over the Tarim Basin, which remained well within the Western Turk orbit.
Gaozong clearly wished to make his own name as an empire-builder and would probably have succeeded in doing so, had he not been scorned by later generations of misogynistic male historians for sharing power with his wife, the formidable Empress Wu . After all, Gaozong did conquer the Western Turk heartland, the Tarim Basin, and Baekje within just three years in 657-660. Eager to take over the entire Western Turk sphere of influence, he also created "bridled" ( jimi ) client prefectures (zhou) and area commands (fu) throughout Sogdiana and Bactria (Tokharisatan) in 659-661. This publicity stunt gave rise to the longstanding and commonly made, but quite disingenuous, claim that at this time, the Tang empire extended all the way to the eastern borders of Iran - even though the Tang had no practical administrative or military control west of the Pamirs.
If one were to take the existence of "bridled" commands as an indicator of incorporation into the Tang empire, then even Silla would have become Tang territory in 660, due to the creation of a bridled prefecture and command with the king of Silla at its head. But even the most "maximalist" interpretations of the Tang empire's size have refrained from making such a blatantly false claim.
- The Tang empire's penchant for conferring "bridled" prefectures and commands on foreign rulers in regions beyond its actual military reach has resulted in numerous modern maps (especially in China) that greatly inflate its size. The map below, from the Chinese edition of Wikipedia, at least distinguishes between "stable" territory (orange), territory "prone to change" (light brown), and "bridled" territory that was never truly under Tang control (unshaded). But it still overstates the extent of both the first and second categories and persists in including even the third category (including Silla!) within the boundaries of "the furthest extent of Tang territory" 唐朝疆域所至, marked by a dark brown line. Such "doublethink" is quite common because of Chinese reluctance to question perceptions of the Tang as China's "greatest" dynasty.
"Map of the Tang dynasty's territory" (2011), from the Chinese-language edition Wikipedia article on the Tang dynasty
As of 669, Gaozong's crowning achievement was the subjugation of Goguryeo, whose defiance had brought down the Sui dynasty and frustrated even Taizong. It is likely, however, that the Tang never exercised effective control over the northeastern corner of Goguryeo's territory (along the Tumen River), where the *Markat (Malgal, Mohe) tribes formerly under Goguryeo's suzerainty would have taken advantage of their overlord's collapse to seize control.
Furthermore, the empire's new frontiers proved extremely unstable and fragile. In Baekje, the Tang occupation force's brutal treatment of the local population (which included pillaging and massacres) had triggered a wave of revolts. Although the resistance movement was crushed in 663, the Tang court's failure to reward and even supply the occupation troops adequately left them disgruntled and demoralized.
Soon, anti-Tang resistance also erupted in occupied Goguryeo (now known as the Andong Protectorate, i.e., the Protectorate to Pacify the East) despite the forced relocation to China of 38,000 households, including the kingdom's entire elite. Before long, Silla, fearing that it would be the Tang's next target, ended its alliance with the Tang and began aiding and providing sanctuary to the Goguryeo rebels, while launching attacks against the Tang occupiers in Baekje.
On the steppe, the eastern Turkic peoples had grown restive under Tang domination after thirty years of contributing fighting men to the empire's seemingly endless wars. An uprising by several Tegreg tribes, including the Uyghurs, had already been put down ruthlessly in 663, necessitating the establishment of a Tang military garrison in the heart of the Mongolian steppe. This Hanhai (Lake Baikal) Protectorate was renamed the Anbei Protectorate (i.e., the Protectorate to Pacify the North) in 669. But ten years later, the Eastern Turks, whom Taizong had resettled in the Ordos region , would also begin to rebel against the Tang.
The Tuygun (Tuyuhun) of Kokonor - Tang vassals since 635 - had succumbed to the Tibetan empire in 663, followed a few years later by up to twelve Qiang "bridled" prefectures on the northwestern Sichuan frontier. The buffer zone that once shielded the Tang heartland from direct Tibetan attack had melted away within just a few years. Now the Tang, its military resources severely overstretched, would have to shift its strategic focus from dominating Korea to containing the Tibetan threat.
The Tang's celebrated recent conquests in Central Asia were slipping away as well. Half of the Western Turk peoples were now resentful and leaderless after the Tang executed their client khagan on false charges around 662. In 662-665, one of these peoples, the Köngül (Gongyue), invited the Tibetan empire into the Tarim Basin and helped it to overrun the new Tang garrisons in Shulik/Kashgar and Khotan. Aksu, west of Kucha, would fall to a combined Tibetan-Khotanese army in 670, forcing the Tang to pull its remaining Tarim Basin garrisons back to Turfan to avoid further disaster.
- Some Japanese and Chinese historians have argued that the Tang briefly reoccupied the Tarim Basin in 674, because the Zizhi tongjian records the king of Kashgar and the leader of the Köngül visiting Chang'an to "surrender" to the Tang emperor in that year, supposedly after being intimidated by the threat of a Tang punitive expedition. The king of Khotan is also reported to have visited the Tang court in 674-675, upon which a "bridled" prefecture was again created in his kingdom. Christopher Beckwith , on the other hand, interprets these kings as refugees who had fled to the Tang after being deposed by the Tibetans in the early 670s. My own interpretation is that because the Tibetans did not station armies continuously in the Tarim Basin, the local city-states and the Köngül were able to maintain a certain degree of independence from outside interference by playing the Tang and the Tibetans against each other and posing as loyal vassals to both sides. During the 670s, the Tang focused its efforts on counterattacking the Tibetans on the Kokonor front. Tang armies did not re-enter the Tarim Basin until the 680s, upon which the local states' autonomy soon came to an end again.
Map 4: Islamic and Tibetan empires, 660-661
Map 4
Map 4 depicts the two most successful expansionist empires of the seventh century, the Islamic caliphate of the Arabs and the Tibetan empire. Both emerged in the 620s and 630s, coinciding with the beginning of Tang expansionism, as the Eastern and Western Turk khaganates collapsed. The empire-building of the Arabs and Tibetans was immense in scale compared to that of the Tang, since they started from a blank slate rather than adding on to a large empire inherited from a preceding dynasty. They were also more successful in consolidating their conquests, whereas the Tang empire's expansionist phase in 630-668 caused much geopolitical disruption but ultimately proved unsustainable.
In fact, the decline of the Western Turks and the Tibetan expulsion of Tang power from Central Asia seem to have emboldened the Umayyad caliphate to extend its imperialism into Sogdiana, with attacks on Bukhara and Samarkand in 674-676. At this time, Tibetan strategy seems to have been more defensive, aimed at preemptively securing Tibet's northern and eastern flanks against Tang encroachment, but it would become more ambitious after the An Lushan Rebellion weakened the Tang western frontiers (see Map 6).
Tang frontier policy continued to suffer setbacks through the remainder of the seventh century. There were a couple of successes, to be sure. In the mid-670s, the Western Turks reunited under new leaders and again allied with the Tibetans against the Tang. In 679, the Tang general Pei Xingjian captured the "rebel" leaders via a cunning scheme, then constructed a heavily fortified outpost at Suyab for the purpose of projecting military power against both the Western Turks and the Tibetans. Operating from both Turfan and Suyab, Tang military forces returned to the Tarim Basin around 686-687 and regained dominance over that region by 692.
But Tang efforts to dominate the western Turkic peoples via more client khagans ultimately proved fruitless, leading to Suyab's occupation by the new, independent Turgesh khaganate around 700. By then, the Eastern Turks of Inner Mongolia had also finally broken free (after two failed attempts), returned to the northern steppe, and rebuilt their empire , ending the fifty-year period of Tang dominance over the eastern Turkic peoples. In 687, the Tang withdrew the Anbei Protectorate from the steppe and relocated it in Ejin (Tongcheng) in western Inner Mongolia, effectively ceding hegemony over the eastern Tegreg to the new Eastern Turk khaganate.
Map of the modern Gansu (Hexi) Corridor, showing the location of Ejin
In 675-676, after several years of inconclusive clashes with Silla armies , the Tang permanently pulled all of its forces out of the Korean peninsula, relocating the Andong Protectorate to Liaodong and leaving Silla free to expand westwards into the former Baekje and northward as far as the Daedong River (just south of Pyongyang) and the bay of Wonsan. The area between the Daedong and Yalu (Amnok) rivers became a stateless buffer zone between the Tang and Silla. But there was worse to come for the Tang.
In 696, the Kitan people of the Liao River region rebelled against Tang suzerainty and captured the prefecture of Yingzhou (Chaoyang, Liaoning), forcing a further retreat from the northeastern frontier. After the fall of Yingzhou, the Tang garrisons on the peninsula - based at the former Goguryeo fortresses of Liaodong (Yodong) and Xincheng (Shinseong) - had to be supplied by sea. The garrisons were probably evacuated around 698, when the Andong Protectorate was abolished. The buffer zone between the Tang empire and Silla then expanded to include Liaodong. In the mountains to the northeast of this zone, there emerged a new kingdom founded by an alliance of Goguryeo refugees and Margat (Malgal/Mohe) tribes. The Tang did reoccupy Yingzhou in 717, but chose not to reoccupy Liaodong and recognized the new Goguryeo-Markat kingdom as a "bridled" vassal state with the name Bohai (Balhae) .
Although the Andong Protectorate was reestablished at Pingzhou (Lulong county, Hebei) in 714 and remained in existence until 761, its headquarters (which moved a few times) was consistently located to the west of the Liao River and there is no record of new Tang garrisons or prefectures being established in Liaodong. It is likely that Andong's purpose shifted to managing relations with the Kitans and Qay and Bohai, rather than controlling Liaodong or the Korean peninsula.
Map 5: The northeastern buffer zone
Map 5
Map 5 depicts the approximate shape of the expanded northeastern buffer zone around 755. It is bounded by the Tang to its west, the Kitans to its northwest, Bohai to its north and northeast, and Silla to its southeast.
Note that due to nationalist biases and ambiguity in the sources, modern historians commonly deny the buffer zone's existence. Chinese historians tend to assume that Tang control over Liaodong and even Pyongyang persisted well into the ninth century or at least until the An Lushan Rebellion, while Korean historians believe that these areas had become part of Bohai by that point, possibly after a period of independence under a Lesser Goguryeo state. These competing interpretations are evident in the maps found in the English , Chinese , and Korean Wikipedia entries on Bohai. Yet neither interpretation is supported by strong evidence.
- The most sensible and balanced discussion of this issue that I have read to date is Kim Jong-bok, "A Buffer Zone for Peace: Andong Protectorate and Diplomatic Relations between Silla, Balhae, and Tang in the 8th to 10th Centuries," Korea Journal 54.3 (2014), 103-125.
A Tang cavalryman patrolling the northern frontier. (Image generated using DALL-E 3)
Map 6: Tang frontiers, ca. 755
Map 6a
In the early 700s, the constant need for frontier warfare against the Tibetans, Turks, and Kitans led the Tang to transition gradually from a system of rotational service by tax-exempt military households in the interior (the fubing ) to one of permanent professional armies on the frontier.
"Map 6" is a series of maps depicting the Tang empire's frontiers and frontier regional commands ( jiedushi ) on the eve of the An Lushan Rebellion of 755-763. By this time, territorial expansion had become extremely difficult for the Tang. Instead, the empire was mostly reduced to holding its current frontiers, suppressing local revolts, and mounting opportunistic raiding expeditions to intimidate and weaken enemies like the Tibetans and Kitans by capturing prisoners, livestock, and horses.
In an age of strategic stalemate, Emperor Xuanzong's penchant for generously rewarding successful raids led frontier commanders to engage in bigger risks and demand bigger budgets. Their armies grew steadily in size and cost. According to contemporary sources, by 742 the frontier armies totaled 490,000 troops, used more than 80,000 horses, and annually consumed about 11.2 million bolts of silk as pay and clothing material. The price of military glory was becoming unbearable for the general population, who bore a heavy burden of taxation in grain and cloth (officials and their families were legally exempt from all taxes).
As of 740, the frontier armies were grouped into eight large regional military commands: Anxi, Hexi, Longyou, Jiannan, Lingnan, Shuofang, Hedong, and Fanyang. Two more commands were created before 755: Beiting (in 741) and Pinglu (in 742), which were split off from Anxi and Fanyang respectively. The core of these armies consisted of full-time professional soldiers recruited from both the Chinese peasantry and the frontier peoples. But they could be augmented by conscripts from the interior, as reflected in two well-known Tang poems: Du Fu's " Ballad of the Army Carts " and Bai Juyi's " The Old Man with the Broken Arm ."
Map 6b: Longyou/Kokonor
Du Fu's poem is a bold criticism of the human and economic cost of the Tang-Tibetan conflict over the fortress of Shibaocheng on the Longyou/Kokonor frontier, which the Tibetans had captured from the Tang in early 742. The final Tang victory in 749 involved 63,000 Tang troops, including reinforcements from the Hexi, Shuofang, and Hedong commands and a contingent of Turkic auxiliary cavalry. Tens of thousands of them died taking a highly defensible fortress defended by just four hundred Tibetans. The Longyou commander responsible for their deaths, the Turgesh-Khotanese Qoshu (Geshu) Han , followed up by conquering the disputed Nine Bends region in 753, earning a promotion to joint command of Hexi and Longyou and enfeoffment as a prince.
In 749, Qoshu Han also stationed a garrison of two thousand troops on Dragon Horse Island (modern Haixin Island) in the middle of Kokonor (Lake Qinghai), but the Tibetans overran the garrison that winter when the lake froze over.
Map 6c: Yunnan frontier
Bai Juyi's poem (composed in the early 800s) tells the story of an old man who, in younger days, chose to escape the military draft by crippling his own arm. This was a few years after the Jiannan command lost most of its troops in a failed attack on the kingdom of Nanzhao , which had rebelled against Tang suzerainty, captured nearby Yaozhou prefecture, and aligned itself with the Tibetan empire. The Jiannan command's regular complement of 39,000 troops had already been doubled to 80,000 for this campaign, most likely via local conscription. Some 60,000 died or were captured in a disastrous rout outside the Nanzhao capital in 751.
- It should be noted that Yaozhou prefecture had always been a remote outpost of Tang power projection into Yunnan, surrounded by "bridled" polities and rather tenuously connected to the Sichuan frontier zone via the prefecture of Xizhou (or Suizhou). As early as 698, a Tang prefect in Sichuan had proposed abolishing Yaozhou on the grounds that many of the 500 Sichuanese troops sent to garrison Yaozhou each year ended up dying en route. The proposal was rejected, as the Tang court considered it strategically necessary to compete with the Tibetan empire for influence over the Yunnan peoples. This strategic competition finally resulted in the Tang-backed Mengshe tribe absorbing five other tribes and creating the Nanzhao kingdom in 737. Nanzhao aided the Tang in suppressing a revolt by the Cuan people of eastern Yunnan in 746-747, but its relations with Tang officials in Sichuan and Yaozhou then rapidly deteriorated as these officials came to see the expansion of Nanzhao power into the former Cuan territories as a threat.
- In 750, King Geluofeng of Nanzhao captured Yaozhou and killed its prefect Zhang Qiantuo. Geluofeng then sought reconciliation with the Tang, laying the blame for his revolt on Zhang Qiantuo. Zhang, Geluofeng claimed, had conspired with Nanzhao's enemies (including the Cuan and Tibetans), levied excessive demands for grain on Nanzhao to weaken it, and secretly planned to destroy his kingdom. [Tang sources, for their part, claim that Zhang Qiantuo had humiliated Geluofeng by having sexual relations with his wife.] The Tang court rejected Geluofeng's justifications and decided to invade and conquer Nanzhao. According to Geluofeng, this imminent invasion forced him into realigning with the Tibetan empire for protection, although some historians suspect that the realignment had already taken place prior to the attack on Yaozhou.
To replace the massive losses sustained in the Yunnan expedition of 751, the government began drafting able-bodied men from the two capitals (Chang'an and Luoyang), Henan, and Hebei and even resorted to press gangs. In 754, these conscripts were used in a second attack on Nanzhao, which failed as disastrously as the first. The Tang army ran out of food when besieging the Nanzhao capital, over 50,000 men died of hunger and disease, and the remaining 20,000 were wiped out when they tried to retreat and were overrun by pursuing Nanzhao troops. The broken-armed old man in Bai's poem reasons that even though his maimed arm aches terribly when it rains, he has no regrets since it is better than dying young on a distant battlefield, which would surely have been his fate otherwise.
Nearly all Tang frontier zones were defined by regular prefectures that governed and taxed the registered Chinese population (divided into counties) while overseeing a number of autonomous client polities ("bridled" prefectures) for "barbarian" peoples beyond the frontier. The "bridled" prefectures typically operated on a principle of hereditary rule by chieftains or kings and paid an irregular "tribute" rather than taxes.
The experience of being a "barbarian" on the Tang frontier was not always a pleasant one. Occasionally, mistreatment of "bridled" chieftains and kings by the local prefect would result in an explosion of violent resistance. This was the case with the Kitan rebellion of 696 and the Nanzhao rebellion of 750. The ruthless methods by which the Tang suppressed such revolts, when it had the power to do so, can be illustrated by the cases of the Sogdian revolt in the Shuofang/Ordos frontier zone in 721-722 and the Lao revolts in the Lingnan frontier zone in 722-728.
Map 6d: South Ordos
The Sogdians of the "Six Hu (Sogdian) Prefectures" (liuhuzhou 六胡州) were descended from Sogdian soldiers who had served the Eastern Turk khaganate. After the Eastern Turks surrendered to the Tang in 630, these Sogdians were resettled in the Ordos region along with their Eastern Turk peers. Like the Eastern Turks, they continued their pastoral nomadic and martial way of life and served as auxiliary cavalry in the Tang empire's wars. In 679, when large-scale revolts began to break out among the Eastern Turks (eventually resulting in a new Eastern Turk khaganate in the 680s), the Tang moved many Sogdians to the southwestern part of the Ordos to separate them from the rebels (who were concentrated in the northeastern Ordos). Six prefectures were established to govern these Sogdians, with Tang officials as prefects - these were thus technically not "bridled" prefectures but semi-regular in nature.
In 721, some 70,000 Sogdians of the six prefectures rebelled against Tang rule, possibly because the Tang court had recently ruled that they must pay taxes in grain, cloth, and corvee labor like regular Tang subjects, rather than the lighter tax in sheep that they had previously paid.
- This explanation for the revolt was proposed by Iwami Kiyohiro: see "Turks and Sogdians in China during the T'ang Period," Acta Asiatica 94 (2008), 41-65.
The Tang responded by mobilizing the armies of the Shuofang and Longyou commands to crush the rebellion. Although the Sogdians enlisted the aid of the Ordos Tanguts to their east, they were still no match for the 10,000 Shuofang troops that attacked them. 15,000 Sogdians were killed, and their leader Kang Daibin was captured and publicly sliced in two in Chang'an, in front of an audience of "barbarian chiefs" who had been summoned to watch the execution for their moral edification.
By the time the Longyou army arrived in the Ordos, the rebellion was already over. But the Longyou troops began plundering the Sogdians anyway, upon which their revolt briefly resumed before being crushed again in 722. This time, the government decided to resettle more than 50,000 surviving Sogdians in southern Henan, spreading them out among the Chinese population to prevent further rebellions. In 738, these Sogdian families were allowed to return to the Ordos, where they were placed under the authority of a new prefecture called Youzhou but still called the "Sogdians (Hu) of the Six Prefectures" out of habit.
In 786, the Sogdians of Youzhou were again resettled in northern Shanxi to prevent them from allying with the Tibetan empire, which by this time was frequently raiding the Ordos due to the contraction of the Tang empire's western frontiers after the An Lushan Rebellion (see below).
Map 6e: Resettlement of the Ordos Sogdians, 630-786
Map 6f: Lingnan frontier
The Tang Chinese referred to the indigenous Tai-speaking and Vietnamese-speaking peoples of the Lingnan frontier by the label " Lao ," a Tai endonym possibly derived from an Austroasiatic word meaning "human being" or "person." Many of these peoples lived in "bridled" settlements known as dong, but others lived in the regular prefectures with Chinese settlers. In the 720s, a wave of revolts swept through the Lingnan region, beginning in 722 with a rebellion in Annan (north Vietnam) led by a native chieftain known as Mei Shuluan or Mei Xuancheng . The rebels were said to number 400,000 but were put down within a year by 100,000 Lao auxiliaries raised from the dong in Guangxi and Guangdong that had remained loyal.
In 726, a Lao revolt in the Yongzhou (Nanning) area of Guangxi, led by one Liang Dahai, captured two prefectures but was also crushed within the year. In 728, the Lao of Chunzhou and Shuangzhou (western Guangdong) rebelled and captured more than forty counties. Their leader Chen Xingfan declared himself an emperor and sought to build an independent state in Lingnan. Again, Chen's forces were defeated within a year by troops mobilized from the prefectures of northern Lingnan, as well as 100,000 crossbow-armed troops from the Huainan region.
The Tang general responsible for crushing each of these Lingnan revolts was Yang Sixu, one of Xuanzong's most trusted eunuchs. Like his more famous colleague Gao Lishi , Yang was himself from the Lao areas of Lingnan but had been castrated and sent to the imperial court as a teenager. By the 720s, he was in his seventies and probably felt little or no attachment to the home he had left many years before.
Yang Sixu became infamous for his sadistic mutilation of prisoners of war, a habit apparently aimed at striking fear in his troops' hearts and thus strengthening his authority over them. The same terror tactics characterized his handling of the Lingnan revolts. Surrendering Annan rebels were massacred and their bodies heaped up into public "mound spectacles" (jingguan) to intimidate the populace; the same treatment was meted out to 20,000 Lao rebels in 726 and another 60,000 in 728. When Yang died in 740, his epitaph credited him with the execution of 200,000 rebels and the building of 81 mound spectacles in all.
Catherine Churchman has recently argued that Yang's massacre in 728 amounted to a "mass depopulation" of the Lao in western Guangdong and eastern Guangxi, as well as the permanent destruction of their chieftain class. They were never again able to mount effective resistance to Tang domination.
- See Catherine Churchman, The People Between the Rivers: The Rise and Fall of a Bronze Drum Culture, 200-750 CE (Rowman and Littlefield, 2016), Chapter 7.
With the Lao further west, however, it was a different story. In 756, less than one year into the An Lushan Rebellion, a massive revolt broke out in western Guangxi, involving a coalition of eight Lao "kings" who collectively are said to have ruled over 200,000 subjects. Tang troops in Lingnan took four to five years to defeat the rebels and recapture the region. The revolt's center was the former "bridled" prefecture of Xiyuanzhou, corresponding to Xialei town in Daxin county, Guangxi, near the present China-Vietnam border. The "Xiyuan Man barbarians" continued to lead the western Lao in periodic revolts and raids against the regular prefectures of Lingnan until the early 830s, when the Tang regional commander for Guangxi attacked their home area and massacred many of them.
Ban Gioc – Detian Falls , on the China-Vietnam border near the former Xiyuanzhou
Map 6g: Tarim Basin, Pamirs, and Gilgit-Baltistan
The sole exceptions to the Tang frontier system of regular prefectures supervising "bridled" prefectures were the Tarim Basin states, which had no regular prefectures but were "protected" from other powers by permanent Tang garrisons stationed in four cities: Agni (Yanqi, Karashahr), Kucha, Khotan, and Shulik (Shule, Kashgar). Each city hosted 6,000 Tang troops on average. The kings of these states retained their autonomy while holding symbolic ranks as prefects under the "bridled" arrangement, provided they remained aligned with the Tang and avoided contact with rival powers like the Tibetans and Turgesh.
The Tang garrisons also established an outpost in the Pamir Mountains sometime after 713, on the site of the now-defunct kingdom of Khabandha, and used it as a staging point for attacks on minor states in Gilgit-Baltistan and Chitral that were aligned with the Tibetan empire. Like Taizong's raids on pro-Turk Tarim Basin states in the 640s, these expeditions typically aimed at regime change by capturing a pro-Tibetan king and replacing him with a pro-Tang candidate.
The Tang was much more reluctant to intervene in the unfolding Umayyad Muslim conquest of Sogdiana , in part because the Muslims' leading opponent in that region was the Turgesh khaganate (based in the former Tang outpost of Suyab), which itself posed a challenge to Tang interests in Central Asia. After the Turgesh khaganate collapsed in a civil war in the late 730s, the Tang failed to gain effective control over its warring factions and finally resorted to destroying the walls of Suyab in 748 - nearly seventy years after building those same walls. As a result, the former Western Turk heartland came to be dominated by new Turkic arrivals from the eastern steppe, the Karluks .
- On Tang attempts at forming an alliance with the Umayyads against the Turgesh in the 730s, see my essay "'What Do Barbarians Know of Gratitude?' - The Stereotype of Barbarian Perfidy and Its Uses in Tang Foreign Policy Rhetoric."
The Tang also got drawn into a conflict between pro-Tang Fergana and pro-Turgesh Tashkent (Chach). When the Tang commander of Anxi treacherously sacked Tashkent and made off with its riches (and its king) in 750, he so alienated the Sogdians that they appealed to their past oppressors, the Muslims (now under the Abbasid caliphate), and invited them to attack the Tang garrisons in the Tarim Basin. The result was the famous Battle of Talas, in which a combined Tang-Fergana-Karluk army intercepted the Muslims, only to be routed when the Karluks changed sides after a five-day standoff. Only several thousand Tang troops escaped death or capture.
- Note that there is no primary source evidence whatsoever (whether in Chinese, Arabic, or Tibetan sources) that a Tibetan army was involved in the Battle of Talas. Somehow, the myth of Tibetan involvement as an ally of the Muslims has made it into Wikipedia articles on the battle in multiple languages (including English Chinese), with dubious Western secondary sources cited if any sources are cited at all. Although Tang sources suggest that a Tibetan-Umayyad alliance sought to wrest Fergana from Tang domination in the 710s and 720s, the Tibetans later realigned with the Turgesh in the 730s. The nature of Tibetan alliances in the 740s and 750s is unclear due to a lack of evidence.
- The Wikipedia article on the Battle of Talas is a mess of inaccurate information, due to unreliable secondary sources and competing ethnocentric/nationalist agendas, and has been so for many years. The most accurate and useful English-language discussion of the battle and its geopolitical context is probably still in Christopher Beckwith's The Tibetan Empire in Central Asia (1987), Chapters 5 and 6. A new treatment of the subject in English, with translations of the Chinese and Arabic sources, is long overdue.
Map 6h: Fergana, Tashkent, and Talas
- Kazakh scholars, citing Arabic accounts of the battle, place its location not at Talas (modern Taraz ) but at nearby Artlakh (or Itlakh), which corresponds to the modern village of Pokrovka . None of the extant accounts of the battle states the size of the Muslim army. The earliest Arabic account, in the Kitāb al-Bad’wa al-Tārīkh written by Mutahhar ibn Tahir al-Maqdisī around 966, exaggerates the size of the Tang army as 100,000, of whom 45,000 were killed and 25,000 captured. A later Arabic source , from 1231 (often wrongly identified as the earliest in Arabic), makes roughly the same inflated claims but adjusts the Tang casualties to 50,000 killed and 20,000 captured. Chinese sources give a rather wide range of sizes for the Tang army as well:
- The biographies of Li Siye in the Jiu Tangshu and Xin Tangshu state 20,000 troops. These are probably based on a private obituary of Li Siye.
- According to the editors of the Zizhi tongjian, Liu Fang's Tangli (completed in the 780s) states "30,000 foreign (Fan) and Tang (Han) troops." Liu Fang was a court historian with access to official records, but the Tangli was a privately compiled chronicle.
- A private biography of Duan Xiushi , composed by Ma Yu in 806-820, states "60,000 foreign and Tang troops." Ma Yu was a court librarian and court historian.
- Du You's Tongdian , completed around 801, claims that 70,000 Tang troops were killed in the battle, though it's likely he exaggerated for rhetorical effect to accentuate the cost of Xuanzong's frontier wars. He inflated the size of the lost garrison on Dragon Horse Island at Kokonor (749) from 2,000 to 20,000, for example.
Given that the regular complement of the Anxi command was 24,000, it's likely that no more than 20,000 Tang troops fought in the Battle of Talas, along with several thousand Fergana and Karluk troops. In any case, the defeat at Talas appears to have reduced the Anxi command to a few thousand men. But it was probably rebuilt to full strength by 753, when it went back on the offensive and mounted a successful raid on the Tibetan client state of Greater Bolor (Baltistān).
As numerous historians have pointed out, the significance of the Battle of Talas in Central Asian history has been greatly overestimated. Even before the battle, the Tang did nothing to prevent the Muslims from conquering Sogdiana. Nor did Tang forces retreat from the Tarim Basin after 751 and leave it open to conquest by the Abbasids. Instead, the Tarim Basin garrisons were overrun by the Tibetans in the 780s and 790s, after being cut off from the rest of the Tang empire for some thirty years as an indirect consequence of the An Lushan Rebellion. And even if the Tang had won the battle and not lost the Tarim Basin to the Tibetans, it would probably have made little difference to the gradual conversion of the Sogdians and the western Turkic peoples to Islam over the next few centuries.
It's also worth noting that Gao Xianzhi , the Anxi commanding general who sacked Tashkent and was defeated at Talas, was of Goguryeo descent but grew up in the Tarim Basin, where his father served as a military officer in the Tang army. His grandparents were probably among the many Goguryeo elite families forcibly resettled in China after 668.
Talas River valley, Kyrgyzstan
Map 6i: Northern frontier
The Turco-Sogdian An Lushan was simultaneously commander of Pinglu and Fanyang after 744 and was also given joint command of Hedong in 751. Later in 751, he lost more than 50,000 troops (drawn from all three commands) in a failed raid on the Kitans, but was evidently successful in replacing these losses within a few years. When he rebelled against the Tang state in late 755, he is said to have had 150,000 troops at his disposal (inflated to 200,000 in rebel propaganda), including the armies of Pinglu and Fanyang and cavalry contingents from his former adversaries, the Kitan, Qay , Tongra, and Shiwei peoples beyond the frontier.
The Hedong army did not participate in the rebellion, as An Lushan had not had enough time to secure its loyalty. He merely dispatched two of his officers and a party of twenty Qay horsemen to incapacitate the Hedong army temporarily by kidnapping its deputy commander from his headquarters in Taiyuan.
In 756, the Pinglu army assassinated its commander (an An Lushan appointee) and declared itself loyal to the Tang court, but was thereafter exposed to attack by Fanyang-based rebel forces on one end and the Kitans and Qay on the other. In 761, it abandoned its headquarters at Yingzhou (Chaoyang, Liaoning) and crossed the Bohai Gulf to Shandong, where the Pinglu command was based thereafter. Interestingly, from 765 to 819 this command in Shandong (effectively an autonomous province) was held by three generations of a military family, the Li , that originally hailed from Goguryeo.
Yingzhou was permanently lost to the Tang and the northeastern frontier retreated further west to Pingzhou ( Lulong, Hebei ) - or, from the opposite perspective, the buffer zone expanded further west to include Yingzhou. Many Chinese historical atlases and maps erroneously depict Chaoyang as Tang territory in the ninth century; in fact, although Yingzhou was reestablished after 763, it was now located in Changli county near Pingzhou.
An Lushan proclaimed himself emperor of a new Yan dynasty and succeeded in capturing Luoyang and Chang'an, defeating armies commanded by Gao Xianzhi and Geshu Han. But he lacked the military resources to build on these gains and expand his territory further; he was also increasingly incapacitated by physical ailments and vision loss (probably caused by gout), which made him violently irascible. His disgruntled son Qingxu assassinated him in early 757 and assumed leadership over the rebel regime.
An Qingxu proved inept and unpopular, losing both Luoyang and Chang'an to Tang loyalist forces aided by the fearsome cavalry of the Uyghur khaganate . He was forced out in 758 by the ruthless rebel general Shi Siming, who achieved a brief revival of the rebellion's fortunes before himself being assassinated by a disgruntled son. That son, Shi Chaoyi, oversaw the final collapse of the rebellion under another joint Tang-Uyghur offensive, after which Tang and Uyghur troops alike subjected the rebel capital at Luoyang and its surrounding region to three months of brutal pillaging.
An Lushan's rebellion led to the gradual loss of the four northwestern frontier zones to the Tibetan empire, starting with Longyou/Kokonor and moving westward over a thirty-year period from 756 to 786. The northwestern frontier commands were severely depleted by the redeployment of troops eastward to reinforce the Shuofang and Hedong commands, which bore the brunt of fighting against the rebels. The final collapse of the Longyou/Kokonor command occurred in late 763, months after the rebellion ended, and resulted in the brief occupation and sacking of Chang'an by a Tibetan army.
By 765 Liangzhou (headquarters of the Hexi command) had also fallen, effectively cutting the empire off from the rest of the Gansu/Hexi Corridor zone and the zones to its west. The Tibetans took twenty more years to overwhelm all the Gansu prefectures, with Dunhuang being the last to fall in 786. The Tang prefectures in the Dzungaria-Turfan-Hami frontier zone and the Tarim Basin garrisons all fell to the Tibetans by the early 790s. The Tibetan and Uyghur empires then began warring over these areas, with the Uyghurs eventually seizing control of Tingzhou (Beiting), Turfan, and possibly the northern part of the Tarim Basin.
The Tang, Tibetan, and Uyghur empires around 805
Note that the Turkic Shatuo people (located in Ganzhou on the map above) defected to the Tang at Lingzhou around 808 and were resettled in the Ordos. In 809, they were moved further eastwards to the area of Yunzhou (Datong, Shanxi), where they served the Tang as frontier cavalry and eventually absorbed the Sogdians who had been resettled from the Ordos in 786 (Map 6e), as well as groups of resettled Tuyuhun and Tegreg.
This enlarged Shatuo entity went on to play a prominent role in the tenth-century Five Dynasties (907-960), during which Shatuo elites created various mythic narratives of their migration to the Tang. For example, they claimed their ancestors to have been loyal Tang allies who were conquered by the Tibetan empire at Tingzhou (Beiting); the Shatuo then migrated to Ganzhou and continued on to Lingzhou, doggedly fighting off pursuing Tibetan forces in their determination to return to the Tang fold. Eleventh-century Song historians doubted these claims and instead suggested that the Shatuo betrayed the Tang defenders of Tingzhou in 790 and, after being resettled in Ganzhou, served the Tibetans as military allies against the Tang and Uyghurs for fifteen years before deciding to defect.
- On this subject, see the recent study by Maddalena Barrenghi, "Representations of Descent: Origin and Migration Stories of the Ninth- and Tenth-century Turkic Shatuo,"Asia Major 3rd series 32.1 (2019), 53-86.
- For other static maps depicting the events of the An Lushan rebellion and the consequent territorial changes, see my series "Maps of the An Lushan Rebellion and Its Consequences."
A Shatuo cavalryman. (Image generated using DALL-E 3)
Map 7: Tang frontiers, ca. 865
Map 7
Map 7 depicts the Tang empire and its northwestern and southwestern frontiers in 865, just over a century after the end of the An Lushan Rebellion. In the 840s, the Uyghur and Tibetan empires both unexpectedly collapsed. While rival Tibetan commanders fought it out in the Kokonor area for two decades, the Chinese elite of Dunhuang rebelled against Tibetan rule, captured most of the Gansu/Hexi Corridor, and declared allegiance to the Tang.
The Tang court recaptured a number of prefectures in eastern Longyou that had been lost to the Tibetans a century earlier, and even sent a force of 2,500 men to garrison Liangzhou (Wuwei, Gansu) around 861, but lacked the military resources and ambition to recover all of Longyou. As a result, the Dunhuang-based Chinese regime (which the Tang court dubbed the Guiyi Army command ) and the Liangzhou garrison remained separated from the Tang empire by a stateless zone populated by pastoral Tibetan tribes, Chinese peasants, and a new ethnic group called the Wenmo that consisted of former Chinese slaves of the Tibetans. Over the next two centuries, the Chinese and Wenmo inhabitants of this buffer zone, as well as Liangzhou , assimilated to a Tibetan identity.
- On this subject, see my essay "Stubbornly Chinese? Clothing Styles and the Question of Tang Loyalism in Ninth-Century Dunhuang."
The lack of direct support from the Tang empire (which in any case began to collapse due to peasant rebellions in the 870s) doomed the Guiyi Army regime's prospects for dominating the Gansu Corridor in the long run.
In the 880s, a group of Uyghurs, probably descended from refugees from the steppe, expelled the Guiyi Army's representatives from Ganzhou (Zhangye) and founded their own state , which later also captured the adjacent prefecture of Suzhou. These Ganzhou Uyghurs were finally conquered by the Ordos-based Tangut Xia state in the mid-1030s.
To the northwest of Dunhuang, another Uyghur state held the Tianshan region and Turfan by 865. Over time, it expanded its influence into the Tarim Basin as far as Agni (Yanqi) and Kucha, possibly absorbing a Kucha-based Uyghur state in the process. By the 1020s, this West Uyghur state appears to have gained control over Dunhuang itself. Dunhuang was eventually conquered by the Tangut Xia state, but the date for this is disputed, with dates proposed ranging between 1036 and 1072.
- The history of relations between the Guiyi Army regime in Dunhuang and the Ganzhou Uyghur and West Uyghur states remains poorly understood and controversial, due to our limited sources. See the up-to-date discussion in Lilla Russell-Smith, Uygur Patronage In Dunhuang: Regional Art Centres On The Northern Silk Road in the Tenth and Eleventh Centuries (Brill, 2005), Chapter 1.
The Tibetan empire's collapse relieved the Tang of its strongest adversary, although the two sides had been at peace since concluding a treaty in 821. It also emboldened the Nanzhao kingdom of Yunnan to attempt expanding into the Tang empire's southwestern and Lingnan frontiers, now that it no longer had to worry about a threat to its west (Nanzhao had broken with the Tibetans and returned to being a Tang ally in 794). In 860, the Nanzhao ruler Longshun (r. 859-877) declared himself an emperor in the Chinese style, a direct challenge to Tang suzerainty that amounted to a declaration of war.
By 860, the corrupt, abusive, and oppressive policies of Tang frontier administrators had so alienated the indigenous "Man" and "Lao" peoples of the Lingnan frontier that they offered to aid and guide invading Nanzhao forces (indicated by dark blue arrows). With their assistance, Nanzhao captured both Hanoi (Jiaozhou) and Nanning (Yongzhou) in 860-861. A Tang counterattack soon retook both prefectures, but Nanzhao attacked again in 863 and this time held Hanoi until 866. The new regional commander for West Lingnan, Kang Chengxun (of Sogdian ancestry), was so inept that a second assault on Yongzhou nearly succeeded in 864.
In 864-865, Nanzhao twice attacked the southern Sichuan prefecture of Xizhou. The first attack failed, but the second succeeded because the local "Lianglin Man barbarians" defected to Nanzhao and opened the city gates, upon which the Nanzhao army entered and massacred the entire Tang garrison. This defection again reflected the problem of frontier mismanagement, as the Xizhou prefect had benefited from the Lianglin Man's military services against Nanzhao as late as 864, but finally lost their loyalty by launching slave raids on them and selling the slaves for personal profit.
Using Haiphong as a staging point, the new regional commander of West Lingnan, Gao Pian , succeeded in recapturing Hanoi in 865-866. But the Tang-Nanzhao war dragged on for ten more years, as Nanzhao adopted a bold but ultimately fruitless strategy of attacking the Sichuan Basin in hopes of capturing the wealthy city of Chengdu (a Nanzhao raid in 829-830 had succeeded in capturing and pillaging a part of that city).
A new Nanzhao ruler, Longshun (r. 877-897), finally initiated peace negotiations that were concluded in the summer of 883 with his marriage to a Tang imperial clanswoman (officially represented as a "princess"). Ironically, by this time the Tang emperor himself was based in Chengdu , as Chang'an had only just been recaptured from the rebel army of Huang Chao .
The Tang empire descended into political collapse and civil war after the Huang Chao Rebellion, but Nanzhao's days were numbered as well. A powerful minister named Zheng Maisi arranged Longshun's assassination in 897, then used Longshun's young son Shunhuazhen as a puppet. Upon Shunhuazhen's death in 902, Zheng massacred the entire royal clan of Nanzhao and founded his own dynasty, Great Changhe (903-927). A period of instability in Yunnan followed, with three short-lived dynasties, before the long-lasting Dali kingdom was established in 937.
- On the Great Changhe kingdom, see Megan Bryson's recent article " The Great Kingdom of Eternal Peace: Buddhist Kingship in Tenth-Century Dali ," Asia Major (2019) 3d ser. Vol. 32.1: 87-111.
The Three Pagodas of Dali
The Song empire
Map 8: Tang and Song frontiers compared
Map 8 compares the pre-755 Tang frontiers and the Northern Song empire's frontiers; swipe right for the Tang and left for the Song. Note that I am limiting the comparison to land frontiers. Maritime frontiers on the coast did become increasingly important in the Northern Song period, as the Song state lifted restrictions on private maritime travel for purposes of commerce - restrictions that had been in force throughout the Tang.
- Hainan island, which I have included in the Lingnan and Guangxi frontier zones, was an unusual case that combined aspects of both land and maritime frontiers. Edward Schafer's Shore of Pearls: Hainan Island in Early Times (1970) gives a good overview of Hainan under the Tang and Song.
Map 8
The "Five Dynasties and Ten Kingdoms" period (907-979) of political fragmentation and instability following the end of the Tang created conditions for the rise of the Kitan Liao empire (founded in 907), the Tangut Xia regime (or Xi Xia, founded in 982), and the Dai Viet state (founded in 968), which ruled parts of the former Tang empire's northeastern, Shuofang/Ordos, and Lingnan frontier zones respectively. As mentioned earlier, the Tangut Xia also conquered most of the Gansu Corridor zone in the 1030s. The Liao conquered Bohai in 926 and also eventually gained suzerainty over the Goryeo state of Korea, which had emerged out of Silla's political collapse in the 890s.
By Song times, Chinese migration to the Lingnan region had changed Guangdong demographically and culturally to the extent that it was no longer viewed as a frontier region. As a result, the Lingnan frontier zone shrank in size and was now limited to Guangxi.
Unlike the Tang, the Song adopted a hands-off approach to the Yunnan-Guizhou frontier, including the Dali kingdom, in part because of the notorious cost of Tang military operations against Nanzhao and in part because of the lack of a geopolitical threat from the Tibetan plateau. Dali in turn did not pursue expansion into the former Tang frontiers. As a result, a buffer zone of independent local polities emerged between Dali and the Song and profited from handling the import of Yunnan horses to the Song (see Map 13 below). Other small local polities in Guizhou evolved into the tusi of Yuan and Ming times.
Map 9: Song northern frontiers (11th century)
Map 9
Map 9 depicts Song northern frontier/border zones in relation to the approximate boundaries of the Kitan Liao and Tangut Xia states (swipe left for the Liao and Xia). Note that depictions of the size of the Liao vary widely. I have chosen a less expansive interpretation of Liao territorial boundaries that distinguishes between Kitan-dominated areas and areas largely inhabited by vassal peoples like the Tatars of Mongolia and the Jurchens of Manchuria.
The territorial extent of the Liao and Xia effectively cut the Song off from potential Inner Asian allies against these enemies, except for Tibetan groups in the Longyou/Kokonor frontier zone and Tangut client groups in the Song-Xia border zone. When the Jurchen people rose in revolt against the Liao in the mid-1110s and began overrunning its eastern frontier, the Song court jumped at the opportunity and negotiated a military alliance. This opportunism proved disastrous, for reasons explained in the commentary to the next map.
Map 10: The Sixteen Prefectures
Map 10
The red stars on Map 10 mark the Sixteen Prefectures ceded to the Kitan Liao empire by the Shatuo-Sogdian warlord Shi Jingtang in 938, in exchange for military aid. The cession of these prefectures in northern Hebei and northern Shanxi gave the Liao control over strategic mountain passes that Chinese empires had previously used to guard against invasion from the north.
Two of the sixteen prefectures (Mozhou and Yingzhou) were recaptured by the Later Zhou dynasty in 959. The subsequent Song dynasty failed several times to reconquer the remaining fourteen prefectures and was forced to renounce its claim to them in a treaty signed in 1005 . The Liao in turn renounced its claim to Mozhou and Yingzhou in exchange for a large yearly subsidy of silk and silver. Song irredentist ambitions toward the lost prefectures lingered on, however, and drove the Song to ally with the rising Jurchen Jin empire in the hope of reclaiming them.
The Jurchens reluctantly handed the fourteen prefectures over to the Song in 1123, in exchange for financial compensation, but their patience with the Song's combination of military ineptitude and arrogance was evaporating rapidly. The Song then overreached by accepting the defection of a Jin official who controlled Pingzhou and Yingzhou (this was the post-763 Yingzhou in Changli county). Pingzhou and Yingzhou, marked on the map with yellow dots, were not included in the Sixteen Prefectures, as the Kitan Liao had seized them before 938, but the Song court believed it had a legitimate claim to them nonetheless. The defector fled to Song territory after being defeated by loyal Jin forces. Although he was subsequently killed to appease the Jin, the Jin now had a pretext for war with the Song, since the newly renegotiated Song-Jin treaty of alliance forbade either side to harbor fugitives from the other.
The Jurchens invaded and conquered north China in 1126-1127, just a few years after destroying the Liao. The Song dynasty only narrowly survived this crisis, as most of the imperial clan was taken prisoner and transported north to Manchuria. In 1141, the Song and Jin agreed to a peace treaty that fixed their border along the line of the Qin Mountains and the Huai River and subordinated the Song to the Jin as a vassal state.
- For more static maps of these events, see my series "Maps of the Jurchen Invasion."
Song infantrymen patrolling near a fort on the Song-Xia border. (Image generated using DALL-E 3)
Map 11: The Song-Xia border
Map 11
Map 11 depicts the Song-Xia border on the eve of the Jurchen invasion. Red dots indicate Song prefectures that existed at the beginning of the Song-Xia conflict. Purple dots indicate military garrisons and fortresses, which did not have a civilian administration as their population was largely military personnel. Green dots indicate Song prefectures created on territory recaptured or recolonized since the 1070s.
The Xia state originated from the Dingnan command in the southeastern Ordos, held by members of the Tangut Li (originally Tuoba) family for a century from 881 to 982 (i.e., from the collapse of the Tang to the rise of the Song). The Tanguts of the Ordos were descended from "Qiang" refugees who had fled the mountains of northwestern Sichuan to evade the expanding Tibetan empire from the 660s to the 680s (see Map 4). The Tang eventually resettled these refugees in the Ordos, to the east of the Sogdians of the Six Hu Prefectures (see maps 6d and 6e). Xiazhou prefecture, the center of the Dingnan command, was in the heart of the Ordos Tangut area and had its capital in the formidable fortress of Tongwancheng (now Baichengzi, Jingbian county, Shaanxi), built by a local Xiongnu ruler in the early fifth century.
Ruins of Tongwancheng
By the time of the first Tangut Dingnan governor, Li Sigong , the Tanguts had called the Ordos home for about two centuries. The last governor, Li Jipeng, was pressured into surrendering his command to the Song in 982, but his ambitious brother Li Jiqian then seized power and submitted to Kitan Liao suzerainty so as to preserve his independence from the Song. The Song, focused on irredentist warfare with the Liao over the Sixteen Prefectures, chose to accept Jiqian as a vassal rather than fight on two fronts.
By the time of his death in 1004, Li Jiqian (now styling himself King of Xia) had conquered much of the Ordos region. His son Deming moved the Xia capital to Xingzhou (later Xingqing fu, modern Yinchuan) in the 1020s and conquered most of the Gansu Corridor in the early 1030s, while outwardly maintaining a subservient posture to the Song. Deming's successor Yuanhao then declared himself an emperor in 1038, asserting equality with his Liao and Song overlords. After a costly war with the Song, in which Xia armies won several victories but also suffered heavy losses, Yuanhao made a peace deal with the Song in 1044. He would go back to being a king in diplomatic correspondence with the Song (while retaining the title "emperor" in internal communications) in exchange for yearly subsidies of silk, silver, and tea modeled on the Song-Liao treaty of 1005.
A Xia cavalryman. The Xia army was known for its heavily armored cataphracts, known as Iron Sparrowhawks (tie yaozi 鐵鷂子). (Image generated using DALL-E 3)
It should be noted that although the Xia was ruled by a Tangut family, Tanguts lived on both sides of the Song-Xia border. The Song prefecture of Fuzhou, in the Song-Liao-Xia border zone, was governed by members of the Tangut She family for about two centuries. Huan-Qing and Fu-Yan circuits on the Song-Xia border were home to many client or "dependent" Tangut groups, some of whom had never served the Xia while others had defected to the Song. Auxiliary troops recruited from these groups played an important role in the Song frontier defense system, especially after the Song-Xia war of 1038-1044. To the west, Jing-Yuan and Qin-Feng circuits also relied heavily on auxiliary troops recruited from the local Tibetans.
In the 1070s, Song strategy shifted from containing and blockading the Xia in the Song-Xia border zone to outflanking it by recolonizing the Longyou/Kokonor frontier. This frontier zone was a strategically important source of horses for the Song cavalry, which was chronically short of mounts, and the last three Northern Song emperors treated its recovery as both a strategic priority and a source of personal prestige. Colonization grew increasingly costly, however, as ill-treatment of the Tibetan population by Chinese settlers and administrators led to native revolts, some of which received assistance from the Xia. For example, a Xia army of 100,000 men intervened to support a Tibetan revolt in Kokonor in 1100, forcing Song forces to pull out from the newly established prefectures of Shanzhou (Xining) and Huangzhou (Ledu). A Song counterattack recovered the two prefectures in 1103-1104.
After the Jurchen invasion of 1125-1127, the Xia conquered some parts of the Song-Xia border, including Xi'anzhou in 1126, Xiningzhou (formerly Shanzhou) and Lezhou (formerly Huangzhou) in 1136, and Fuzhou in 1139. The other areas came under Jurchen Jin rule.
- For an eye-opening new analysis of the lasting environmental impact of Song fortification and colonization strategies on the Song-Xia border, see Ruth Mostern, The Yellow River: A Natural and Unnatural History (Yale University Press, 2021), Chapter 3.
Map 12: The Song-Jin war, 1161
Map 12
Map 12 illustrates the importance of both riverine and maritime naval warfare to the defense of the Song after its retreat from north China.
In 1161, the Jurchen Jin emperor Wongian Di'unai (known in Chinese as Wanyan Liang) led an invasion aimed at capturing the "Southern Song" capital Lin'an (Hangzhou). The land prong of the invasion force (represented by the dark blue arrows) set out from Kaifeng, easily breached the Song defenses on the Huai River, and advanced to the northern bank of the Yangzi River. The seaborne prong, reportedly 600 warships carrying 70,000 troops, assembled at Tang Island, off modern Qingdao in Shandong, in preparation for sailing down the coast and into Hangzhou Bay.
The light blue arrows mark the operations of the Song general Li Bao, who had 120 warships with 3,000 militiamen from Zhejiang and Fujian under his command. Li's fleet sailed up the coast from the mouth of the Yangzi River, helped the Song general Wei Sheng to repel a Jin attack on the prefecture of Haizhou (newly seized from the Jin as a staging point for a counterattack), and then on November 16 attacked the Jin fleet at Tang Island with incendiary arrows before boarding the Jin ships for close-quarter combat. The Jin commanders were reportedly inexperienced at naval warfare and suffered total defeat. Li Bao thus eliminated the seaborne threat to the Song at one stroke.
Ten days later, Wongian Di'unai's army attempted a crossing of the Yangzi River at Caishi . The crossing failed when the cumbersome Jin transport ships were intercepted and destroyed by a fleet of Song paddle-wheel ships and larger seagoing vessels that launched gunpowder bombs from their trebuchets. Di'unai moved his army east to Yangzhou (see dotted dark blue arrow) and prepared to make another crossing, but he was assassinated on December 15 by disgruntled subordinates. The Jin army then withdrew to the original Huai River border. A Song counterattack on the Jin made only limited progress, so the two sides negotiated a new peace treaty (signed in 1165) with no territorial changes but with terms more favorable to the Song than before (e.g., the Song emperor was now officially a junior kinsman to the Jin emperor, not a vassal).
More than one century later, the Mongols succeeded in overcoming the Southern Song's naval defenses by building and training a large and effective navy, in part using ships and sailors captured from the Song, and by sailing down the Han River into the middle Yangzi after capturing the fortress of Xiangyang in 1273.
- A detailed account of the battles of Tang Island and Caishi and the building of the Yuan navy can be found in Lo Jung-Pang, China as a Sea Power 1127-1368 (Singapore: NUS Press, 2012 [1957]), 154-168, 211-246.
Map 13: The Guangxi frontier
Map 13
Map 13 depicts the Song empire's Guangxi frontier stretching from Guilin (the local administrative capital) in the east to the kingdoms of Dali and Dai Viet in the west. The administrative units pertain to ca. 1175, nearly fifty years after the Song lost north China to the Jurchens.
Note that only selected regular prefectures (yellow squares) and counties (yellow dots) are shown. Green dots mark border outposts known as zhai (stockades). Red dots mark "bridled" prefectures - essentially native "Lao" chieftaincies under Song influence and supervision.
Green areas mark the approximate boundaries of native peoples and kingdoms that lay beyond the control of the Song state. The "Mountain Yao" were hemmed in by Song regular prefectures on three sides and frequently had violent conflicts with Chinese settlers. Song relations with more distant groups were generally peaceful and even mutually beneficial, as the Luodian and Ziqi kingdoms made a good profit by buying horses from Dali and selling them to the Song at Hengshan Stockade.
- Most of the information for this map was taken from Fan Chengda's Guihai yuheng zhi . A good annotated translation of this work by James Hargett is available, but the small map printed on p. xx of the translation does not depict topography or the locations of "barbarian" peoples. The location of Yongping Stockade on my map is based on a recent article by Zhou Junkai 周君愷, "Yongping zhai jianzhi yan'ge kao," 永平寨建置沿革考, in Minzushi yanjiu 民族史研究 2017, pp. 173-189. Users of the Hargett translation should note that I have used the more common translations of zhou 州 as "prefecture" and xian 縣 as "county," rather than Hargett's translation of these terms as "county" and "town" respectively.
Ha Long Bay , Vietnam, near the border with China
The Guangxi frontier was heavily militarized in the eleventh century. This was due in part to the aggressive state-building efforts of local leader Nong Zhigao (Nùng Trí Cao), who hailed from the same region as the "Xiyuan Man" of late Tang times. Other contributing factors include continued Song irredentism toward Dai Viet, Dai Viet attempts at controlling the peoples of western Guangxi, and the lack of a clearly defined border between the two states. After an indecisive border war between Dai Viet and the Song in 1075-1077, triggered by Viet fears of Song encroachment, the two sides agreed on a fixed border and refrained from aggressive actions.
- On this subject, see James Anderson, The Rebel Den of Nùng Trí Cao: Loyalty and Identity Along the Sino-Vietnamese Frontier (University of Washington Press, 2007).
Map 14: Mongol invasion of Guangxi, 1259
By 1175, the Guangxi frontier had been relatively peaceful for nearly a century, apart from occasional raids and revolts by the Yao and Lao. The peace was not broken until the 1250s, when the Mongols - who had already seized north China and part of Sichuan - conquered Dali (1253), invaded Dai Viet (1257-1258), and then sent an army from Dai Viet into Guangxi in 1259. This army, commanded by Uriyangkhadai , comprised 3,000 Mongol cavalry and 10,000 infantry from Dali and is indicated by the red arrow on Map 14 below. It overran Hengshan Stockade, annihilated a Song army of 60,000, captured Guilin, and then entered Hunan to besiege Tanzhou (Changsha). Meanwhile, another Mongol army under Khubilai (indicated by the black arrows) had crossed the Huai River and the Yangzi River from north China to besiege Ezhou (Wuchang). When the Mongol Khan Mongke died (probably of disease) while besieging Diaoyu fortress in Sichuan, Khubilai decided to lift his siege of Ezhou and return to north China to stake his claim to succeed Mongke. Uriyangkhadai then also lifted his siege of Tanzhou and marched his army north to join Khubilai, defeating a Song army of 20,000 men that tried to cut off his retreat.
- For an analysis of Uriyangkhadai's expedition that corrects some past misconceptions, see Stephen G. Haw, "The Deaths of Two Khaghans: A Comparison of Events in 1242 and 1260." Bulletin of the School of Oriental and African Studies 76, no. 3 (2013): 361-71.
Map 14
Mongke's death and the resulting civil war between Khubilai and his brother Ariq Böke gave the Southern Song a short reprieve, during which chief minister Jia Sidao attempted to strengthen the state fiscally and militarily through controversial land redistribution reforms aimed at increasing revenue. These proved unsuccessful and highly unpopular with the literati elite. As a result, when the Mongols again invaded in the 1270s, now with greatly improved siege artillery and naval forces, the Song defense collapsed within a matter of years and south China became the Mongol empire's last major conquest.
"Kings and Generals" web documentary (2018) on the Mongol civil war of 1260-1264 and the conquest of Southern Song
Map of the Mongol empire (by Ian Mladjov )