The reign of Emperor Xuanzong is considered the most glorious period of the Tang dynasty. It began when he led a coup d'etat that overthrew Empress Wei, and would last for 44 years. When Xuanzong became emperor he found that the government had been looted by extensive corruption that had existed for decades. He immediately undertook cost cutting measures that included his own household staff. Xuanzong ordered his empress, consorts, and the women in his concubine not to wear or buy pearls, jade, embroidery, or brocades. He also stopped wealthy families from establishing Buddhist monasteries so that they could evade taxes. At the same time he ordered 30,000 monks to return to lay life(life outside of the church) and start paying taxes.
In order to increase revenue, Xuanzong sent agents to re-register families who had fled southward during the invasions of the Khitan and the Turks. These families were not on the tax roll. He offered them a form of tax amnesty and as a result re-registered more than 800,000 families. This provided his treasury with a windfall of more than 1 billion in cash over the next decade.
Before long, the Chinese began to prosper under Emperor Xuanzong's leadership. At the same time,the economy was aided by his expansion of granaries, which helped keep inflation very low. In 719 Xuanzong constructed granaries all over China. Ample grain storage allowed local officials the opportunity to buy grain when it was at its cheapest. This action prevented starvation and famine. He also established law and order by putting an end to highway banditry. Next, Xuanzong increased agricultural production by reclaiming land. Soon afterward he improved the canal system so that the cost of transporting the grain could be reduced. Xuanzong also stopped taxing the bottom 5% poorest families in each village, distributed government land to the poor, and he improved both health care and education. He also supported poetry, and the arts. Xuanzong established the Pear Garden Troupe that trained musicians and singers. He personally selected the 300 performers. The Troupe only performed at his palace for his pleasure.
Xuanzong kept China at peace whenever possible by using diplomacy. However, it would take military action to contain the nomadic tribes that were raiding from the north in search of slaves, grain, and livestock. Peace was also helped by the permanent army that was created to guard the frontier. These were both militia and cavalry units. During his reign the only large threat to China's borders came from Tibet. By the year 742, his highly skilled army contained more than 500,000 men.
In 736, Emperor Xuanzong delegated duty to two of his ministers who ruled like dictators. Not long afterward, Xuanzong became obsessed with one of his son's wives. Then in 740, he had her abducted from his sonís mansion. Five years later he elevated her to the highest level of consorts(second wives). Her name was Yang Guifei, and she loved dance. Both Yang and Xuanzong were accomplished musicians. They spent their time indulging in pleasure. Yang had her relatives appointed to high paying positions. Their love story, and the tragic end of her life are the foundation for the most famous love story in the history of China. Xuanzong's reign and Yang's life both came to an end with the rebellion of An Lushan.