Through a series of military and political moves, the kingdom of Silla (57 B.C–676 A.D.) achieves dominance over most of the Korean peninsula by the end of the seventh century. Its campaign of unification begins with the defeat of the Gaya Federation in 562; after an alliance with the Chinese Tang (618–907) court, it succeeds in conquering the kingdoms of Baekje in 660 and Goguryeo in 668. By 676, Silla forces Chinese troops to withdraw into Manchuria, and for the first time in history the peninsula comes under the sway of a single Korean government. In the succeeding Unified Silla period (676–935), Korean culture flourishes, creating a political and cultural legacy that will be handed down to subsequent rulers of the country.
Consolidation of the three kingdoms under a single absolute ruler leads to an increase in the wealth of the aristocracy, whose status is secured by a rigid hereditary class system. Gyeongju, the capital of Unified Silla, is a prosperous metropolis with magnificent palaces and imposing Buddhist temples. Officially sanctioned as the state religion, Buddhism exerts a profound influence on the arts; some of the most refined and sophisticated Buddhist art and architecture in East Asia is produced in Korea during this period. The Unified Silla court maintains close relations with Tang China through trade and diplomatic exchanges. Throughout this period, Korea continues to play a crucial role in the transmission of technology and ideas to Japan.
Beset by power struggles between the court and the aristocracy, Unified Silla declines in the late eighth century. The rise of local military garrisons and landed gentry, coupled with increasing unrest among the common people, lead to a deterioration of the social fabric and the establishment of competing regional states. In 918, Wang Geon (877–943), a high-ranking military official, reunites the country under the new Goryeo dynasty (918–1392).