Yang Gao was born in 607, after Emperor Yang had already become emperor. His mother was Consort Xiao, of whom little is known, and she might have been a sister or a relative of Emperor Yang's wife Empress Xiao. In 613, he was created the Prince of Zhao. Yang Gao was said to be intelligent and handsome in his childhood, as well as filially pious—such that when Emperor Yang was ill and unable to eat, Yang Gao would refuse to eat as well, and when Empress Xiao was ill and considered moxibustion, he volunteered to undertake it first. Emperor Yang, when he was under siege by Tujue's Shibi Khan Ashina Duojishi in 615 at Yanmen (雁門, in modern Xinzhou, Shanxi), was recorded as so desperate that he was not doing anything except holding Yang Gao and crying.
In 618, while Emperor Yang was at Jiangdu (江都, in modern Yangzhou, Jiangsu), forces participating in a coup led by the general Yuwen Huaji entered the palace and surrounded him. Yang Gao was by his side, and started crying bitterly. Perhaps in irritation or perhaps to show Emperor Yang that the coup leaders were serious, Pei Qiantong (裴虔通) seized Yang Gao and killed him with a sword in Emperor Yang's presence, with Yang Gao's blood spilling onto Emperor Yang's clothes. Emperor Yang then offered to commit suicide, but was strangled to death instead. Empress Xiao and her ladies in waiting had to take decorative wooden boards within the palace to make makeshift caskets for Emperor Yang and Yang Gao.