Protectorates (duhufu 都護府), headed by protectors-general (duhu 都護), were administrative units in the Western Territories (xiyu 西域) during the first half of the Tang period 唐 (618-907). The term was first used for the Protectorate of the Western Territories (Xiyu duhufu 西域都護府) during the Han period 漢 (206 BCE-220 CE). The central government of the Tang bestowed the title of protector-general on native chieftains and so made them part of an indirect system of rule (jimi 羈縻) over distant regions. The staff of the protectors constited of vice protectors-general (fu duhu 副都護), aides (zhangshi 長史), commanders (sima 司馬) and other officials. The administrative structure of the protectorates slightly imitated that of regular prefectures (fu 府), with civilian and military sections, or such for household registration, granaries, revenue, jurisdiction, or military affairs. There were three different classes of prefectures, depending on the size and the military importance. The heads of supreme protectorates were called da duhu 大都護, and had a superior position in the social structure of the empire, equal to that of imperial princes. The first protectorate was that of the Pacified West (Anxi duhufu 安西都護府). Other important protectorates were Beiting 北庭都護府, Yanran 燕然都護府 (later called Hanhai 瀚海都護府, Yunzhong 雲中都護府, the Pacified North 安北都護府, or the Khan's Protectorate 單于都護府), the Pacified East 安東都護府, the Pacified South 安南都護府 and Baoning 保寧都護府. These were the six protectorates (liu duhufu 六都護府) of the Tang period. Apart from these, there were also the protectorates of the Eastern Barbarians 東夷, Kunling 昆陵 and Mengchi 蒙池.
The Protectorate of the Pacified West (Anxi duhufu 安西都護府) or Beiting were governed from Gaochang 高昌, which was renamed Xizhou 西州. It was founded in 640, and eight years later, the seat of government was transferred to the city of Qiuci 龜茲, from where the four important cities (sizhen 四鎮) of Qiuci, Shule 疏勒, Yutian 于闐 and Yanqi 焉耆 could be controlled. At the same time, the area command (dudufu 都督府) of Yaochi 瑤池 was founded. It was headed by Ashina Helu 阿史那賀魯, khan of the Western Turks 西突厥. In 653 Ashina rebelled, and the seat of the protectorate was shifted back to Xizhou. After the rebellion was put down, the territory of the Turks was divided into the two protectorates of Mengchi and Kunling, and Qiuci again became the centre of the Pacified West. In 661, with the conquest of the Tokhara, the two lesser protectorates of Yuezhi 月支 and the "Great Khan" Dahan 大汗 were founded. In 702 the Pacified West was split into two parts, divided by the Tianshan Range 天山. The northern part was during the 8th century gradually conquered by the Türgish 突騎施 and the Qarluqs 葛邏祿, and the southern part by the Tibetan kingdom of Tubo 吐蕃.
The Protectorate of the Pacified East (Andong duhufu 安東都護府) belonged to the circuit (dao 道) of Hebei 河北 and was founded after conquest of Goryeo in 668, with the seat in Pyongyang 平壤. Apart from parts of the Korean Peninsula, it controlled the Mohe tribes 靺鞨 in the northeast. Because the Koreans pelled out the Chinese, the seat was transferred to Liaodong 遼東. In 726 the chieftain of the Heishui Mohe 黑水靺鞨 from the Amur River region was made head of the area command of Heishuo 黑水都督府. The office of the protector was regularly taken over by the commander-in-chief (dudu 都督) of Youzhou 幽州, and the seat was gradually taken back to the west, from 743 on it was in Liaoxi 遼西 (today's Yixian 義縣, Liaoning). In 719 the office was taken over by the military commissioner (jiedushi 節度使) of Pinglu 平盧, and soon abolished.
The Protectorate of Yanran (Yanran duhufu 燕然都護府) was subordinate to the circuit of Guannei 關內. If was founded after the submission of the Syr Tardush 薛延陀 in 646 and the defeat of all Tölösh 鐵勒 tribes. The area command (dudufu) of Hanhai included all Uyghurian tribes, that of Yanran the Duolangge tribe 多濫葛, that of Jinwei 金微 the Pugu 仆骨, Youling 幽陵 the tribe of the Bayegu 拔野古, Qiulin 龜林 the Tongluo 同羅 tribes, and Lushan 盧山 the Sijie tribe 思結. The protectorate also included prefecures under which various other tribes were administered. Gaolan 皋蘭 (Hun tribe 渾), Gaoque 高闕 (Huxue tribe 斛薛), Jilu 雞鹿 (Xijie tribe 奚結), Jitian 雞田 (Adie tribe 阿跌), Yuxi 榆溪 (Qibi tribe 契苾), Dailin 蹛林 (other Sijie tribes), Shiyan 寘顏 (Baixi tribe 白霫), and Xuanque 玄闕 (Gulihan tribe 骨利幹). Various Qarluq tribes were later also incorporated into the protectorate of Yanran. Its seat was in "Khan's Terrace" Shanyutai 單于臺 (today's Rear Hanggin Banner 杭錦後旗 in Inner Mongolia). In 633 it was moved into the territory of the Uyghurs and was renamed Protectorate of Hanhai 瀚海都護府, and from 669 on called Protectorate of the Pacified North (Anbei duhufu 安北都護府). It fell apart when the Tölösh tribes rebelled. Yet in 685 it was revived, with the seat in Juyanhai 居延海 (Ejin Banner 額濟納旗, Inner Mongolia), which was soon removed to Xi'an 西安 (Minle 民樂, Gansu), and in 699 to Zhonggu 中古 (Horinger 和林格爾, Inner Mongolia). In the next half century or so the seat was often transferred to other places. In 757 the protectorate was renamed Protectorate Securing the North (Zhenbei duhufu 鎮北都護府), but it had lost its function at that time and is only rarely seen in sources after that date. The Protectorate of Hanhai was part of that of Yanran, and for some decades identical to it. The name Protectorate of Yunzhong (Yunzhong duhufu 雲中都護府) was used because the city of that name war for some time its seat. In 664 it was renamed Protectorate of the Khan (Shanyu duhufu 單于都護府), and in the 840s became part of the Protectorate of the Pacified North.
The Protectorate of the Pacified South (Annan duhufu 安南都護府) was part of the circuit of Lingnan 嶺南, and belonged to the defense structure in the border region of Jiaozhou 交州 (today northern Vietnam). The seat was in Songping 宋平 (approx. modern Ha Noi). The office of protector-general was concurrently taken over by the regional inspector (cishi 刺史) of Jiaozhou. In 757 it was renamed Protectorate Securing the South (Zhennan duhufu 鎮南都護府), and in 766 Protectorate of the Pacified South (Annan duhufu 安南都護府), a designation from which the colonial name Annam is derived. In 860 the seat of the protectorate was conquered by the kingdom of Nanzhao 南詔, but it was soon restored, with the seat in the garrison of Haimen 海門鎮 (close to Hai Phong), and then back in Jiaozhou. In 867 the military commissioner of Jinghai 靜海 took over the functions of the protector-general, yet the protectorate was only abandoned with the fall of the Tang dynasty.
The Protectorate of Baoning 保寧都護府 was located in the circuit of Jiannan 劍南 and was founded to forestall the intrusion of the Tibetans into the southwestern regions. It was founded around 750, with the seat in Suomochuan 索磨川 (Aba 阿壩, Sichuan). After the rebellion of An Lushan it was abolished.