The Annan Protectorate was an administrative division established by the Tang Dynasty in northern Vietnam during the era of Northern Domination, spanning from 679 to 907. Prior to 679, as the Tang Dynasty began its rule in Jiaozhou, governance was initially organised as the Jiaozhou General Administration (622–624) and later as the Jiaozhou Area Command (624–679). From the establishment of the Annan Protectorate until 757, it was locally administered as one of the five defence commands within the Lingnan Circuit. After 757, Annan came under the authority of the military commissioner (jiedushi) of Lingnan until 862, when the Lingnan Circuit was divided into East and West Circuits, placing Annan under the Lingnan West Circuit. In 866, the Jinghai Military Command was established in Annan, marking its role as a frontier defence command (fangzhen). In terms of bureaucracy, from 679 to 866, the Annan Protectorate was led by a protector general, with a frontier commissioner appointed during times of rebellion or unrest. From 866 to 907, the head official held the title of jiedushi, while also retaining the role of protector general.