Emperor Daowu of Northern Wei

After the Former Qin fell into disarray in 383 following its defeat by Eastern Jin forces at the Battle of Fei River, Tuoba Gui took the opportunity to reestablish Dai in 386.

Emperor Daowu was commonly regarded as a brilliant general, but cruel and arbitrary in his rule, particularly toward the end of his reign.

His mother was Tuoba Shi's wife Heiress Apparent Helan, the daughter of the powerful tribal chief and Dai vassal Helian Yegan (賀蘭野干).

Tuoba Shiyiqian temporarily fled his capital Yunzhong (雲中, in modern Hohhot, Inner Mongolia), but returned after Former Qin retreated.

Little is known about Tuoba Gui's life until 385, by which time Former Qin, which had come close to uniting all of China, had fallen into great disturbance in light of rebellions throughout the empire.

In 384, Liu Kuren had attempted to aid Fu Jiān's son Fu Pi, who was then under siege by Murong Chui, the founder of Later Yan, but was assassinated by Muyu Chang (慕輿常), the son of a Later Yan noble; he was succeeded by his brother Liu Toujuan (劉頭眷).

Then, later, in order to avoid having the people know Tuoba Gui's status as a traitor to his father, the official version of his personal history was manufactured.

These difficulties apparent in the official version include: Whether Cui Hao, the prime minister of Tuoba Gui's grandson Emperor Taiwu of Northern Wei, propagated this version, and whether that contributed to Emperor Taiwu's execution of not only himself but his entire clan, is not completely clear, but appeared likely.

In spring 386, Tuoba Gui set his capital at Shengle (盛樂, in modern Hohhot, Inner Mongolia), and was said to encourage agriculture to try to rest his people.

In 388, he sent his cousin Tuoba Yi the Duke of Jiuyuan to offer tributes to Murong Chui but also to observe the Later Yan court, to consider whether he would have eventual chance of attacking it.

Early in his reign, Tuoba Gui was considered to be a benevolent and merciful ruler who encouraged his people to take up agriculture.

In 391, Tuoba Gui attacked Rouran—which had been a Dai vassal but had never submitted to him—inflicting major damage on Rouran, but was unable to destroy it.

Tuoba Gui, hearing about Murong Bao's army, abandoned Shengle and retreated west across the Yellow River.

Tuoba Gui selected the talented men amongst the captives to be his own officials, wanted to release the others back to Later Yan to show his mercy.

Tuoba Gui was afraid that slaughtering the captives would endanger his reputation in Later Yan, but he followed their suggestion and executed the remainder, though he would soon regret this.

When his generals tried to persuade him to suspend the campaign, Tuoba Gui gave a response that might be quite demonstrative of his personality: Around the new year 398, with Tuoba Gui ready to attack Yecheng, Yecheng's defender Murong De abandoned it and fled south of the Yellow River, to Huatai (滑台, in modern Anyang, Henan), where he declared an independent Southern Yan state.

He moved the capital from Shengle south to Pingcheng (平城, in modern Datong, Shanxi), to be in greater proximity with the conquered territories.

To replace them, he created eight artificial tribes, placed in the newly declared capital region to supervise agricultural practice in the area.

During the middle period of his reign, Tuoba Gui was still considered to be a lenient emperor, despite his actions at Canhe Slope and against Liu Weichen.

An example of his continued leniency would be that the generals of Murong Bao, Zhang Xiang (張驤), Li Chen (李沈) and Murong Wen (慕容文) had defected from Later Yan to Northern Wei but then back to Later Yan, yet when they were captured, Tuoba Gui pardoned them - but Zhang Xiang's son would soon after lead a rebellion against him, while Li Chen was later involved in a rebellion soon after Tuoba Gui's death.

At this time, he commissioned the officials Cui Hong and Wang De (王德) to revise the simplistic Dai legal code, and in their project abolished Later Yan laws that were considered to be cruel or difficult to follow.

In a display of cruelty and power, he ordered the captured Gaoche men to use their bodies as a wall on a hunt he carried out months later, to stop animals from escape.

However, according to Tuoba tribe customs, he was required to make the potential candidates try to forge golden statues, to try to discern divine favor.

Furthermore, due to Emperor Daowu's military prowess and established governance, many surrounding tribes submitted to him during this period.

In the early to mid 400s, Emperor Daowu had ambitions to conquer the south of China,[7] and although his general Baba Fei (拔拔肥) seized much of the land of Shandong, he withdrew troops from the region when Yao Xing launched his invasion, and he never actually engaged in major wars with Eastern Jin.

He also made increasing visits to Chaishan Palace (豺山宮, in modern Shuozhou, Shanxi), often spending months there at a stretch.

His family were afraid and attempted to flee to Later Qin, but Tuoba Gui pursued and executed them - and then, because the official Deng Yuan (鄧淵)'s cousin had a good relationship with the Suhe family and had been told of the escape plan, Emperor Daowu believed that Deng Yuan also knew of the plan and forced him to commit suicide.

Also in 407, because Tuoba Zun, when he was drunk, had improper sexual relations with the Princess Taiyuan (太原公主; likely a cousin of Emperor Daowu's), he was forced to commit suicide.

Tuoba Shao was said to be a reckless teenager, who often visited the streets in commoner disguises, and often robbed travelers and strip them naked for fun.

In fall 409, Emperor Daowu had an argument with Consort Helan, and he imprisoned her and planned to execute her, but it was dusk at the time, and he hesitated.

Caparisoned horse figurine, Northern Wei
Funerary figurines of armoured cavalry from Northern Wei
Battle of Canhe Slope in which Tuoba Gui defeated the kingdom of Later Yan