After the expedition of Nguyễn Hoàng to reclaim Lê territory in the South from Mạc garrison force, Northern dynasty only controlled the provinces from Thanh Hoa up North.
The nobles and their clansmen switched side frequently to the extent that loyal retainers such as Prince Mạc Kính Điển were praised even by their foes as rare virtuous men.
However, Mac family members had maintained an autonomous rule in Cao Bằng under the protectorate of Chinese dynasties until 1677.
The degenerated Lê dynasty, which endured under six rulers between 1497 and 1527, in the end was no longer able to maintain control over the northern part of the country, much less the new territories to the south.
Mạc Đăng Dung, being a scholar-official who had effectively controlled the Le for a decade, then proclaimed himself the new emperor of Vietnam in 1527, and established the Mac dynasty.