Li Yuan was born in 566 in Longxi County to Li Bing, a dignitary and general of the Tabgach (Tuoba) Northern Zhou dynasty. His aunt, Dugu Jialuo, was the wife of Yang Jian—the future founder of the Sui dynasty. After Yang Jian’s accession, Li Yuan spent some time at court and was then appointed governor of a remote province. Emperor Yang Jian, not favorably disposed toward his wife’s relatives, preferred to keep his nephew away from the center.


Under the next Sui ruler, Emperor Yangdi (a maternal cousin of Li Yuan), Li Yuan’s steady involvement in military service began: in 605 he received a cavalry command; in 613 he took part in the campaign against Goguryeo, proving himself a capable commander; and in 615–616 he helped suppress peasant uprisings.
The turning point came with Li Yuan’s appointment as governor of Taiyuan (Shanxi) in 616–617. There he repelled raids by the Eastern Turkic Khaganate and tried to contain the rebellions tearing the Sui Empire apart. The tasks proved extremely difficult: the khaganate’s troops had entrenched themselves on Chinese territory, and the rebel xiaowei Liu Wuzhou seized the north of present-day Shanxi and parts of central Inner Mongolia, proclaiming himself emperor. An enraged Yangdi demanded at the start of 617 that Li Yuan appear at court to explain himself. In this situation, the eighteen-year-old Li Shimin persuaded his father to raise a revolt.
The core of the uprising’s staff consisted of Li Yuan’s elder sons—Li Jiancheng, Li Shimin, and Li Yuanji—his son-in-law Chai Shao, the magistrate of Jinyang Liu Wenzheng, and the court administrator Pei Ji. Li Shimin became the de facto leader and proposed a political scheme: secure Yangdi’s abdication in favor of the underage Yang You, and have Li Yuan govern as regent in his name.
Li Yuan’s first move was to secure control over Taiyuan by executing the vice-governor Wang Wei and the general Gao Junyu, whom he accused of collusion with the Eastern Turks. He then made peace himself with the khagan Shibi, ceding part of the territory—this gave him freedom to maneuver.
In mid-617 Li Yuan, leaving Li Yuanji in Taiyuan, marched on Daxing at the head of a 30,000-strong army. On the way he received a letter from the rebel general Li Mi, who was rapidly gaining strength and besieging Luoyang. To tie down Yangdi’s main forces, Li Yuan recognized Li Mi’s leadership in writing and declared that he had no personal ambitions, thereby prompting Li Mi to increase pressure on the Sui capital.
Advancing toward Daxing, Li Yuan captured the city of Huoyi by stratagem—luring the troops of General Song Laosheng out of the fortress and destroying them in ambush. After the victory he rewarded all who distinguished themselves equally, regardless of origin; he forbade the killing of prisoners and townspeople, released captives, and gave those who had come from afar funds for the road home. This policy quickly bore fruit: imperial soldiers and officials deserted to his side en masse. Soon all of Guanzhong in the Wei River valley was occupied, and Li Yuan’s army approached Daxing.
In October 617 the city was besieged and soon fell. Demonstrating loyalty to the Sui dynasty, Li Yuan placed the twelve-year-old Yang You (later Emperor Gong) on the throne, while Yangdi, then in Jiangdu, was granted the title taishang huang (“Grand Supreme Emperor”). Yang You conferred on Li Yuan the title Prince of Tang (Tang-wang) and the post of chancellor (chengxiang), effectively handing him the reins of government.
By spring 618 the Sui crisis had become irreversible. In March, conspirators led by General Yuwen Huaji strangled Yangdi; Yuwen proclaimed his nephew Yang Hao emperor and himself became chancellor. In Luoyang, Yang Dong was enthroned; in Wuwei, Li Jing seized power; in Jincheng, the self-proclaimed emperor Xue Ju established himself; and in the southern regions claimants multiplied as well. The strongest among them remained Li Mi.
In this setting, Li Yuan formally accepted the “insistent requests” of Yang You to abdicate in his favor, and on June 18, 618, he was proclaimed emperor and founded the Tang dynasty. The capital was Daxing, soon renamed Chang’an.
Having secured the throne, Li Yuan suppressed pockets of resistance: he took Jincheng, ruled by Xue Rengao (son of the late Xue Ju), and Wuwei, where Li Jing had set himself up. Li Mi, acknowledging defeat, came to court, was shown favor (the emperor married a cousin to him and granted him office), but within the same year he was treacherously killed along with his close associates. In less than three years, the Tang court’s authority extended over most of the former Sui Empire.
The economy, exhausted by Yangdi’s policies and civil war, demanded immediate action. Li Yuan restored the “equal-field system” (juntian zhi): an adult man received 70 mu, a woman 30 mu (1 mu = 1/16 hectare); rent was collected in grain, silk, or cotton, and every able-bodied man performed 20 days of corvée labor annually on public works. This reduced peasants’ dependence on large landholders and stabilized the rural economy.
Monetary circulation was regularized: after the turmoil, the circulation of numerous low-quality coins minted by various contenders complicated transactions; market oversight was strengthened, and market supervisors across the empire were appointed personally by the emperor.
In personnel policy, Li Yuan restored and centralized the civil service examination system (keju), opening the way into the bureaucracy for talented men of humble origin. In 624 the first version of the Tang Code came into force—a codification that combined Confucian and Legalist principles and became a model for subsequent legal codes.

The main threat remained the Eastern Turks. Fortresses were erected along the eastern frontier for defense; however, a decisive solution came later, in 626, at the climax of the succession struggle.
By designating his eldest son, Li Jiancheng, as heir, Gaozu thereby sidelined the popular general and statesman Li Shimin. The tension erupted into civil war. On July 2, 626, Li Shimin killed Li Jiancheng and Li Yuanji. On July 5, Gaozu who then had no surviving sons other than Li Shimin declared him heir, and a few weeks later abdicated in favor of his son. Thus began the reign of Emperor Taizong.
Receiving the title taishang huang, Li Yuan lived two more years in the Taiji Palace with no significant changes to his daily routine. In 629 he moved to a more modest residence. In summer he refused to go to the Jucheng Palace, where Emperor Wen had died; therefore, Li Shimin began building a new summer complex, Daming, for him. Li Yuan died in mid-635, before the construction was completed.



