It is not known when Tuoba Yu was born, but it is known that he was the youngest of Emperor Taiwu's six sons who survived childhood. His mother Consort Yujiulü (i.e.
Lu Zuo Zhaoyi) was a sister of
Rouran's Chilian Khan
Yujiulü Wuti, who had become an imperial consort of Emperor Taiwu's as part of a peace-marriage arrangement in 434, whereby he married Consort Yujiulü while marrying his sister or cousin Princess Xihai to Yujiulü Wuti. He was created the Prince of Wu in 442, and 450, when his father was counter-attacking after a major
Liu Song attack, and Crown Prince Huang was defending the northern borders against a potential Rouran attack, Prince Yu was left in charge of the capital Pingcheng (平城, in modern
Datong,
Shanxi), a sign that Emperor Taiwu trusted his abilities. In 452, his title was changed to Prince of Nan'an. Sometime late in Emperor Taiwu's reign, Tuoba Yu became friendly with Emperor Taiwu's eunuch
Zong Ai, who in 451 had falsely accused Crown Prince Huang's associates Chouni Daosheng (仇尼道盛) and Ren Pingcheng (任平城) of crimes, causing many members of Crown Prince Huang's staff to be executed and Crown Prince Huang himself to fall ill in fear and die. In spring 452, in fear that Emperor Taiwu would punish him, Zong assassinated Emperor Taiwu. The officials initially did not announce Emperor Taiwu's death, but were debating between whether to make Crown Prince Huang's oldest son Tuoba Jun or Emperor Taiwu's oldest surviving son Tuoba Han (拓跋翰) the Prince of Dongping emperor. Zong, who was also on poor terms with Tuoba Han, summoned Tuoba Yu to the palace instead, and forged an edict of Emperor Taiwu's wife
Empress Helian to ambush and put the officials in favor of either Tuoba Jun or Tuoba Han to death. He then executed Tuoba Han as well and made Tuoba Yu emperor. == Brief reign ==