Founding of the Tang
Also called: Tang dynasty
Amid the collapse of Sui, Li Yuan (Emperor Gaozu) rose at Taiyuan, took Chang’an and founded the Tang in 618. In 626 his son Li Shimin (Taizong) took over after the Xuanwu Gate Incident.

Unknown author · Public domain · Source
As revolts spread across Sui after the failed Goguryeo campaigns, Li Yuan, commander at Taiyuan, raised an army in 617 and took Chang’an. When Emperor Yang was murdered at Jiangdu the next year, Li Yuan declared himself emperor (Gaozu) and founded the Tang. His family belonged to the Guanlong aristocracy of mixed Xianbei and Chinese descent that had ruled since Western Wei and Northern Zhou, and was related by marriage to the Sui house.
His second son, Li Shimin, did most to defeat the rival warlords and reunite China by about 624. The Wude code of 624 laid down the equal-field system and the zu-yong-diao tax. In 626 Li Shimin killed his elder brother, the crown prince Li Jiancheng, and his younger brother Li Yuanji at the Xuanwu Gate, the north gate of the palace in Chang’an, became crown prince and two months later received the throne from his father.
The Tang lasted about three centuries and became the centre of an East Asian cultural sphere built on law codes, Buddhism, Confucianism and Chinese characters. Goguryeo exchanged prisoners from the Sui wars with the Tang in 622, and Silla and Baekje too vied to court the Tang.