Han dynasty Goguryeo became a significant independent kingdom in the first century, and began expanding its power in the region.
Taejodae conquered neighboring
Okjeo and
Dongye, and made repeated attacks against the Chinese commanderies and incursions into Liaodong, which would be continued by his successors. Pressure from Liaodong forced Goguryeo to move their capital in the Hun River valley to the
Yalu River valley near
Hwando.
Cao Wei In 244,
Guanqiu Jian, a general of Han's successor state
Cao Wei, defeated
Dongcheon and briefly occupied and sacked Goguryeo's capital. Wei invaded again in 259 but was defeated at Yangmaenggok; according to the
Samguk Sagi,
Jungcheon assembled 5,000 elite cavalry and defeated the invading Wei troops, beheading 8,000 enemies.
Lelang commandery As Goguryeo extended its reach into the
Liaodong Peninsula, the last Chinese commandery at
Lelang was conquered and annexed by
Micheon in 313, bringing the remaining northern part of the Korean peninsula into the fold. This conquest resulted in the end of Chinese rule over territory in the northern Korean peninsula, which had spanned 400 years.
Former Yan During the winter of 342, the
Xianbei of
Former Yan, ruled by the
Murong clan, attacked and destroyed Goguryeo's capital, Hwando, capturing 50,000 Goguryeo men and women to use as slave labor in addition to taking the queen mother and queen prisoner and exhuming the body of
Micheon, and forced
Gogukwon to flee for a while. The Xianbei also devastated
Buyeo in 346, accelerating Buyeo migration to the Korean peninsula.
Gwanggaeto the Great repulsed the enemy troops. In 402, Gwanggaeto retaliated and conquered the prominent fortress called 宿軍城 near the capital of Later Yan. In 405 and again in 406, Later Yan troops attacked
Goguryeo fortresses in Liaodong (遼東城 in 405, and 木底城 in 406), but was defeated both times. By conquering Liaodong, Gwanggaeto recovered the ancient domain of
Gojoseon; The Sui Empire reconquered
Vietnam and defeated
Champa, sacking its capital, and conquered important lands in northern China and
Central Asia against Turks, Tibetans and proto-Mongolians. In 598,
Goguryeo made a preemptive attack on
Liaoxi, leading
Emperor Wen to launch a counterattack by land and sea that ended in disaster for Sui. In 612,
Emperor Yang mobilized a huge force said to number over a million men and invaded Goguryeo. Unable to overcome the defenses of Yodong (Liaodong) Fortress, Emperor Yang ordered 305,000 troops to attack the Goguryeo capital of
Pyongyang. according to Chinese historical records: of the 305,000 Sui troops, a mere 2,700 returned. Emperor Yang lifted his siege of the
Korean fortress and withdrew his forces back to China. He attacked Goguryeo again in 613 and 614, but failed against Goguryeo's defensive strategies, fierce resistance, and able leadership; Emperor Yang's disastrous defeats in Korea greatly contributed to the collapse of the Sui dynasty.
Tang dynasty of
Samarkand. They are identified by the two feathers on top of their head. 648-651 CE,
Afrasiyab murals, Samarkand.
Emperor Taizong ascended the
Tang throne in 626, and led many successful military campaigns. In 630, Emperor Taizong
defeated the Eastern Turkic Khaganate, an ally of Goguryeo, bringing much of
Central Asia under Tang control; he then conquered the
Tarim Basin, and defeated the
Tibetan Empire in 640. In 643,
Queen Seondeok of
Silla requested military aid against the Goguryeo–Baekje alliance. Tang forged an alliance with Silla, and began preparations for a major campaign against Goguryeo in 644. In 645, Emperor Taizong personally led a
campaign against Goguryeo by land and sea with 113,000 Tang troops plus an unspecified number of tribal auxiliaries. Arriving outside Ansi Fortress on July 18, Emperor Taizong prepared to meet an approaching relief army, said to number 150,000 men, in battle. Emperor Taizong ordered
Li Shiji to bait the Koreans with 15,000 troops, while
Zhangsun Wuji's concealed troops would ambush them from behind. Unable to breach the adamant fortress despite months of siege, Tang eventually staked everything on the construction of a huge mound, designed to tower over the walls of the fortress; however, the defenders captured and successfully held the mound despite three days of frantic assaults by Tang troops. Furthermore, exacerbated by worsened conditions for the Tang army due to cold weather (and winter approaching) and diminishing provisions, Emperor Taizong was compelled to order a withdrawal from Goguryeo on October 13, Emperor Taizong attacked Goguryeo again in 647 and 648, but was unsuccessful. Defeating Goguryeo had been an obsession with Emperor Taizong, and after his death in 649, his son
Emperor Gaozong continued his ambition. Upon the suggestion of
Kim Chunchu, the Silla–Tang alliance first conquered
Baekje in 660 to break up the Goguryeo–Baekje alliance, and then turned its full attention to Goguryeo. However, Emperor Gaozong, too, was unable to defeat Goguryeo led by
Yŏn Kaesomun; one of Yŏn Kaesomun's most notable victories came in 662 at the
Battle of Sasu (蛇水), where he annihilated the Tang forces and killed the invading general Pang Xiaotai (龐孝泰) and all 13 of his sons. Hence, while Yŏn Kaesomun was alive, Tang could not defeat Goguryeo.
Fall and aftermath In 666 (though dates vary from 664–666), Yŏn Kaesomun died of natural causes and a civil war ensued among his three sons. His eldest son and immediate successor,
Yŏn Namsaeng, defected to
Tang and provided the secrets and weaknesses of Goguryeo to
Emperor Gaozong, and played a critical role in the next invasion and downfall of Goguryeo. Yŏn Kaesomun's second son,
Yŏn Namgŏn, resisted in the face of death, as opposed to his brother's treachery, and fought until the very end. Meanwhile, Yŏn Kaesomun's younger brother, Yŏn Chŏngto, defected to the Silla side. The Tang–Silla alliance mounted a fresh invasion of Goguryeo in 667, aided by the defector Yŏn Namsaeng,
Silla thus unified most of the Korean peninsula in 668, but the kingdom's reliance on Tang China had its price. Tang China attempted to impose its rule over the entire Korean peninsula, but Silla, aided by Goguryeo and Baekje refugees, forcibly resisted and expelled Tang. However, Silla's unification of the
Three Kingdoms of Korea was short-lived because the former Goguryeo general
Dae Joyeong led remnants of Goguryeo, united with the
Mohe people, and established
Balhae, a successor of Goguryeo. Balhae eventually reconquered and retained much of Goguryeo's former territory. The
Tang dynasty Goguryeo general
Gao Juren ordered a mass slaughter of
Sogdian Caucasians from West and Central Asia, identifying them through their big noses and lances were used to impale Caucasian children when he stormed Beijing (
Jicheng (Beijing)) from
An Lushan when he
defeated An Lushan's rebels. Balhae became a powerful empire like its predecessor, but its eventual end came at the hands of the
Khitan Empire in 926. Balhae's end was a decisive event in Northeast Asian history for it was the last Korean kingdom to hold territory in
Manchuria. Goguryeo was revived once more in 918 by successor state
Goryeo, founded by
Wang Geon, a descendant of Goguryeo nobility. In 937, much of the ruling class and the
last crown prince of collapsed
Balhae fled to Goryeo, where he was warmly welcomed and included into the ruling family by Wang Geon, thus unifying the two successor nations of
Goguryeo. ==Conflicts with nomadic states==