北元
北元（，1368年9月14日－1388年11月1日或1635年6月12日）是由孛兒只斤家族退居蒙古高原之後統治的元朝殘存政權。北元始於元惠宗至正二十八年（1368年），終於元天元帝天元十年（1388年），為「都沁·都爾本」（明朝稱韃靼與瓦剌）所取代。
至正二十八年（1368年），明太祖朱元璋建立明朝，之後派遣徐達領兵進攻元朝首都大都，元惠宗妥懽貼睦爾被迫放棄大都，北走上都。因國號仍稱「大元」，以其地處塞北，故稱之為「北元」。此時的北元仍控制著中書省的西部地區、嶺北行省、遼陽行省、甘肅行省、陝西行省，以及位於西南的飛地雲南行省等省份，仍保有一定的力量，其「引弓之士，不下百萬眾也；歸附之部落，不下數千里也。」與明朝南北對峙，這是中國歷史上又一個南北朝時期。
經過與明朝的幾次戰爭，北元先後失去幾十萬兵力，再也無力南下與明朝相爭，元惠宗試圖恢復中原故土的企圖徹底失敗。元惠宗病重時，皇太子愛猷識理達腊已總理軍國重事，元惠宗死後即位，是為元昭宗。而在即位的隔年（1371年），元昭宗建年號「宣光」，立意仿效周宣王姬靜、漢光武帝劉秀等中興帝王一樣中興大元，恢復元朝在中原的統治。宣光八年四月十三日（1378年5月10日），元昭宗去世，其弟元天元帝脫古思帖木兒繼位，繼續和明朝對抗，屢次進攻明朝邊境。天元十年十月初三日（1388年11月1日），阿里不哥後裔也速迭兒殺害元天元帝，廢除大元國號，國號復稱「蒙古」（明朝稱之為「韃靼」），北元滅亡。北元的滅亡，對於明朝而言是失去了政治上的敵人，蒙古已經成為了「邊患」，而不再是前一個中原王朝的殘餘勢力。
自天元十年（1388年）也速迭兒殺害元天元帝篡位稱汗之後，蒙古開始逐漸分裂為東部韃靼（蒙古本部）、西部瓦剌、韃靼東部兀良哈三大部落。元天元帝敗亡之後歷經四代傳至坤帖木兒時，鬼力赤於明建文四年（1402年）殺害坤帖木兒，繼而登上大汗之位。明正統三年（1438年），瓦剌部的脫歡扶植大汗脫脫不花擊敗同時並立的大汗阿岱，統一了蒙古諸部。明正統十四年（1449年），脫歡之子也先入侵明朝，俘虜明朝皇帝明英宗朱祁鎮，史稱土木堡之變。達延汗與滿都海哈屯在15世紀重新統一蒙古諸部，史稱達延汗中興。然而，達延汗在帝國以封地的名義分封於其兒子與親戚，導致了帝國統治的權力下放。儘管權力下放，但是達延汗與蒙古貴族之間仍保持著良好的關係，孛兒只斤家族的內鬥並不嚴重，直到林丹汗統治期間（1604年－1634年），蒙古內部的紛爭中削弱了自身的力量。明崇禎八年四月二十八日（1635年6月12日），林丹汗之子額哲投降清太宗皇太極當時統治的後金政權，元太祖成吉思汗建立的大蒙古國歷經430年之後正式宣告滅亡。
1368年至1635年之間存在的蒙古政權有多種名稱，其中包括「北元」。與元朝一樣，「大元」國號在1368年至1388年之間正式使用。元天元帝死後，「大元」國號與中國皇帝尊號被篡位的也速迭兒廢除，因此「北元」這個名稱有時候在使用上受到限制，僅指代1368至1388年。「北元」的「北」用於區分1271年建立的元朝和1368年以後的政權。「大元」國號在達延汗統治期間短暫重新啟用，其汗號「達延」來自「大元」的音譯。此外，有證據表明，脫脫不花與也先在統治期間也曾經重新啟用「大元」國號與漢制稱號。
在英語中，「北元」一詞通常用於涵蓋1368年至1635年的整個蒙古歷史。除了「大元」（1388年之前與達延汗統治期間）之外，蒙古人仍然繼續稱作「大蒙古國」。在某些現代文獻中，它也被稱為「後蒙古帝國」、「蒙古汗國」 ，儘管大多數這些英語術語也可以指代在13－14世紀的蒙古帝國或元朝。
在蒙古歷史中，這一時期也稱為「四十與四的蒙古政治分裂時期」，意思為四十個東部蒙古部落和四個西部蒙古部落的政治分裂時期，或稱其分別為四十萬戶及四萬戶。此外，蒙古史學還使用「政治分裂時期」、「蒙古的政治動亂時期」以及「14－17世紀的蒙古帝國時期」等。
在中外蒙古史學者的論著中，屢見「北元」一詞，但是長期以來，對於這一史學概念的使用範疇卻眾說不一。爭論的焦點就是「北元」是指1368年－1388年這20年間的蒙古還是指1368年－1635年這268年間的蒙古。傳統說法是1402年鬼力赤殺害坤帖木兒，為北元時期結束的時間。關於這個問題，蔡美彪與曹永年曾作過深入探討，認為「北元」應適用於元天元帝脫古思帖木兒敗亡而止，即1388年，此後大元國號已取消，仍稱蒙古。大元國號的廢棄一定意義上意味著蒙古政權放棄爭奪中原的目標，轉為立足於蒙古本身。
「北元」僅指大蒙古國的一個階段，其根據是：
「北元」（1368年－1388年）僅代表一個時期的結束，其後進入《明史》所說的韃靼時期（為明朝一方所稱，蒙古方面一直以蒙古自稱）。但是從成吉思汗開始的「大蒙古國」政權仍然繼續，韃靼政權長期沿用元朝時代的漢制職官（如也先的官職為太師淮王），至達延汗時才基本取消。大蒙古國政權延續至1635年察哈爾部為滿洲的後金所滅亡。
故大蒙古國（1206年－1635年）依照中國名稱的劃分，可劃為蒙古（1206年－1271年）、元朝（1271年－1368年）、北元（1368年－1388年）、韃靼（1388年－1635年）。有時「元朝」可泛指從金泰和六年（1206年）元太祖成吉思汗建立大蒙古國到至正二十八年（1368年）元惠宗妥懽貼睦爾撤離大都，長達162年的這段「蒙元時代」。
至正二十八年正月初四日（1368年1月23日），明太祖朱元璋建立明朝，統一南方，令徐達北伐中原，徐達率領的軍隊逼近大都。至正二十八年閏七月二十七日（1368年9月9日），元惠宗命淮王帖木兒不花監國，慶童為中書左丞相；至正二十八年閏七月二十八日（1368年9月10日），元惠宗在清寧殿，召集三宮後妃、皇太子、皇太子妃，一同提議撤退北走上都。失列門及知樞密院事黑廝、宦者趙伯顏不花諫言不可行，元惠宗不聽，趙伯顏不花慟哭勸諫：「天下者，世祖之天下，陛下當以死守，奈何棄之！臣等願率軍民及諸怯薛歹出城拒戰，願陛下固守京城。」元惠宗依然不聽諫。夜半，開大都的健德門北走上都，率三宮後妃、皇太子愛猷識理達臘，以及群臣扈從者左丞相失列門、平章政事兼知樞密院事哈刺章、平章政事臧家奴、右丞定住、參知政事哈海、翰林學士丞旨李百家奴、觀音奴等百餘人撤離大都。至正二十八年八月初二日（1368年9月14日），明軍從大都的齊化門攻城而入，監國淮王帖木兒不花，中書左丞相慶童，平章迭兒必失、朴賽因不花，右丞張康伯，御史中丞滿川等人拒絕投降而殉國，元朝在中原的統治結束，回到本土蒙古草原。
元惠宗撤離大都後，繼續使用「大元」國號，當時高麗人稱作「北元」。這時候，元朝除了據有嶺北等處行中書省、遼陽等處行中書省、甘肅等處行中書省等行省之外，擴廓帖木兒、李思齊、張良弼等元朝將領還武裝控制著陝西等處行中書省及中書省的西部地區（今山西省），在西南雲南等處行中書省仍奉北元正朔。此外，北元仍與高麗國保持了宗主國與藩屬的政治關係，也透過回回與畏兀兒商人和今新疆維吾爾自治區、中亞細亞等地保持著經濟上的聯繫。
至正二十八年八月初四日（1368年9月16日），元惠宗到達上都。至正二十八年九月二十八日（1368年11月8日），明將常遇春攻陷保定，再攻陷真定。至正二十八年十月初三日（1368年11月13日），明將馮勝、湯和攻陷懷慶，澤州、潞州也相繼被攻陷。至正二十八年十二月初一日（1369年1月9日），明將徐達攻陷太原，擴廓帖木兒敗走甘肅行省；至正二十九年正月二十五日（1369年3月3日），常遇春攻陷大同，元朝失去中書省的西部地區。
至正二十九年三月初六日（1369年4月12日），明將徐達攻陷奉元，改奉元為西安，元將張良弼敗走；至正二十九年三月十二日（1369年4月18日），明將常遇春攻陷鳳翔，陝西行省平章李思齊敗走臨洮。至正二十九年四月初一日（1369年5月7日），晃火帖木兒、也速分成二路以大都為目標進軍。至正二十九年四月初七日（1369年5月13日），也速進攻永平失敗。至正二十九年四月十一日（1369年5月17日），明軍攻陷鞏昌，總帥汪靈、真保等人投降，忽都帖木兒留守上都。至正二十九年四月十三日（1369年5月19日），李思齊投降。
至正二十九年六月初五日（1369年7月8日），也速與明將常遇春於全寧開戰，也速最後戰敗。至正二十九年六月十二日（1369年7月15日），明軍攻陷大興，中書右丞脫火赤被俘虜。至正二十九年六月十三日（1369年7月16日），明軍逼近上都，元惠宗撤離上都，當天到達應昌。河南王普化、中書平章政事鼎住等人留守上都。至正二十九年六月十五日（1369年7月18日），晃火帖木兒率領的元軍於新開嶺一戰敗於明軍，晃火帖木兒戰死。至正二十九六月十七日（1369年7月20日），明將常遇春攻陷上都，河南王普化、中書平章政事鼎住等人殉國。至正二十九年七月十九日（1369年8月21日），擴廓帖木兒的手下將領韓札兒攻克原州，又攻克涇州，想要藉此救援慶陽。明將馮宗異自驛馬關率領明軍迎擊，韓札兒的元軍敗退。至正二十九年八月二十一日（1369年9月22日），徐達攻陷慶陽，元將張良臣戰死，陝西等處行中書省失陷。
至正三十年正月初三日（1370年1月30日），明太祖發動第一次北伐，派遣明將徐達、李文忠、湯和分成三路來犯，三寶奴持元惠宗的詔書徵召擴廓帖木兒。至正三十年（1370年）二月，明將李文忠攻陷興和，進軍察罕腦兒，平章政事竹貞戰敗被擄。至正三十年四月初七日（1370年5月2日），擴廓帖木兒與明將徐達於沈兒峪交戰，擴廓帖木兒戰敗而退走哈拉和林 ，其麾下元軍盡皆投降明朝。
至正三十年四月二十八日（1370年5月23日），元惠宗因痢疾在應昌去世，享年51歲。皇太子愛猷識理答臘在應昌繼承皇位，是為元昭宗，並於1371年改元宣光。至正三十年五月初九日（1370年6月3日），太尉蠻子、平章政事沙不丁、朵兒只、八剌等人率領的元軍敗於明將李文忠，開平丟失，平章政事上都馬等人投降；太尉買驢於落馬河與明將孫興祖一戰，兵敗戰死。至正三十年五月十六日（1370年6月10日），明將李文忠攻陷應昌，元昭宗次子買的里八剌與后妃皆被明軍擄獲，元昭宗撤至哈拉和林，擴廓帖木兒在不久之後也到達哈拉和林，元昭宗於國事上重用他，並堅持抵抗明軍。
宣光元年二月二十八日（1371年3月15日），元朝遼陽行省平章劉益派遣右丞董遵、僉院楊賢投降明朝，進獻降表、遼東地圖及所屬兵馬錢糧的數額，明朝控制遼東地區（今遼寧省南部）。然而之外的遼陽行省仍由元朝太尉納哈出控制，納哈出屯兵二十萬於金山（今遼寧省昌圖金山堡以北遼河南岸一帶），自恃畜牧豐盛，與明軍對峙了十幾年，多次拒絕明太祖的招撫。納哈出知兵善戰，在他統治下，遼陽行省長期保持穩定，成為北元政權的重要支柱並保證了北元與高麗的聯系。
鎮守雲南行省昆明的元朝梁王把匝剌瓦爾密，在元朝對中國的統治結束，退居蒙古草原後依然繼續忠效北元，前大理國王室後裔段氏則據有大理，處於半獨立狀態，與梁王政權之間不時發生武裝衝突。宣光元年（1371年），明太祖派湯和等人領兵攻滅據有四川的明玉珍的明夏政權，西南地區僅剩雲南未歸附明朝，之後多次派遣使者前往談判，均被殺害，導致日後決定用武力統一雲南。
漢名王保保的蒙古人大將擴廓帖木兒仍然在漠北多地與明將徐達等人作戰。明太祖曾多次寫信詔降，但擴廓帖木兒從不理會，被明太祖稱為「當世奇男子」。宣光二年正月二十六日（1372年3月1日），明太祖發動第二次北伐，徐達從雁門出發進攻哈拉和林，負責中路；李文忠則是從居庸出發，經應昌進攻哈拉和林，負責東路；馮勝從蘭州出發攻取甘肅行省，負責西路。宣光二年三月二十日（1372年4月23日），擴廓帖木兒先是與明將藍玉在土剌河（今土拉河）一戰佯敗，誘敵深入。宣光二年五月初六日（1372年6月7日），擴廓帖木兒的元軍於嶺北行省大破明軍，負責中路的徐達的明軍陣亡萬餘人。元朝太師哈剌章在土剌河與阿魯渾河（今鄂爾渾河）一帶與負責東路的明將李文忠交戰多日，哈剌章的元軍於宣光二年六月二十九日（1372年7月29日）這天敗退。李文忠的明軍追至稱海時，各路元軍會合之後又發動攻勢。李文忠認為無法取勝，雖未像中路的徐達一樣慘敗，但是明將曹良臣等人也戰死沙場，損失慘重，就決定撤兵而回，只有負責西路的馮勝的明軍連戰連捷。宣光二年六月初三日（1372年7月3日），元軍在瓜州、沙洲兩地敗於馮勝，元朝被明朝奪取甘肅等處行中書省。自此之後，明軍十幾年不再進攻漠北。
宣光三年二月初三日（1373年2月25日），元昭宗派遣伯都帖木兒、玉山不花出使到訪高麗國，以璽書賜高麗恭愍王王顓：「頃因兵亂，遷於北。今以擴廓帖木兒為相，幾於中興。王亦世祖之孫也，宜助朕復正天下。」二人剛入境時，恭愍王想要派人殺害伯都帖木兒等人，群臣阻攔，於是北元使團被送到高麗國首都開城。宣光三年二月初六日（1373年2月28日），恭愍王在夜裡會見伯都帖木兒，說自己有眼疾，不能見太陽，只能待在夜裡，其意思是害怕明朝知道此事。宣光三年二月十三日（1373年3月7日），兩人只能返回北元，恭愍王也向北元獻上苧布。
宣光八年四月十三日（1378年5月10日），元昭宗去世，其弟元天元帝脫古思帖木兒於宣光八年四月十六日（1378年5月13日）繼位，明年六月改元天元，其屬下丞相驢兒、哈剌章，國公脫火赤，平章完者不花、乃兒不花，樞密知院愛足等元軍將領聚眾於應昌與哈拉和林二地，對於明太祖的招降都堅持不從，繼續和明朝對抗，屢次進攻明朝邊境。
天元二年（1380年）二月，國公脫火赤、樞密知院愛足率領上萬元軍於哈拉和林屯紮，得知此事的明太祖發動第三次北伐，派遣沐英率領陝西等處承宣布政使司的明軍進攻北元。天元二年三月二十一日（1380年4月26日），脫火赤、愛足的元軍於亦集乃與沐英的明軍交戰，最後在哈拉和林被擊敗，脫火赤、愛足被俘虜，其麾下元軍投降。同年冬季，平章完者不花也被明軍俘虜
天元三年正月初二日（1381年1月27日），乃兒不花率領元軍進攻明朝邊境。明太祖發動第四次北伐，派遣徐達、湯和、傅友德率領明軍迎擊。天元三年四月十五日（1381年5月9日），徐達率領明軍分東西兩路出擊，灰山的元軍被傅友德的東路明軍夜襲而敗，人畜皆被奪取。北黃河（今西遼河）的元軍聞訊之後落荒而逃，明軍追擊，平章別里不花、太史文通等人被俘虜。知院李宣與其部眾則是被從古北口出發，直搗高州、嵩州、全寧諸部，渡過臚朐河（今克魯倫河）的沐英的西路明軍俘虜。北元因此丟失全寧四部。
天元三年九月初一日（1381年9月18日），明將傅友德、藍玉、沐英率軍南征雲南行省。天元三年十二月十八日（1382年1月2日），司徒平章達里麻的十餘萬元軍在曲靖的白石江敗於明將傅友德，達里麻被俘虜。天元三年十二月二十二日（1382年1月6日），認為局勢已經無法挽回的梁王把匝剌瓦爾密來到晉寧州忽納寨焚燒龍衣，並帶著妻、子於滇池自殺殉國，左丞達的、右丞驢兒也一同自殺殉國。天元四年閏二月二十三日（1382年4月7日），明將藍玉、沐英攻陷大理，元朝大理總管段世投降明軍，至此明軍平定雲南等處行中書省全境，元朝在雲南的統治結束。從1253年元世祖忽必烈滅大理國，到1382年明軍擊敗元軍奪取雲南，元朝統治雲南地區長達128年。
天元九年（1387年），這時擴廓帖木兒已逝世，元軍也大多被消滅或投降明朝，唯獨納哈出仍擁有二十萬元軍駐軍於金山，數度窺伺遼東地區。天元九年正月初二日（1387年1月21日），馮勝、傅友德、藍玉等人發動第五次北伐，目標是攻占納哈出的金山。經過多次戰爭，天元九年六月二十九日（1387年7月14日），納哈出投降藍玉，元朝失去遼陽等處行中書省。納哈出的投降對於北元而言不僅是一記沉重的打擊，也切斷了北元與高麗國之間的聯絡。更使北元朝廷在軍事、經濟方面遭受了巨大損失，因為失去了東部屏障，以呼倫貝爾、克魯倫河一帶為政治中心的北元朝廷直接暴露在大寧明軍的兵鋒之下。
天元十年（1388年）三月，明將藍玉率領明軍十五萬發動第六次北伐，明軍從大寧出發，穿越過戈壁沙漠到達草原東部的慶洲。天元十年四月十二日（1388年5月18日），藍玉在捕魚兒海（今貝爾湖）附近大敗元軍，俘虜元天元帝次子地保奴及妃主五十餘人、渠率三千、男女七萬餘，馬駝牛羊十萬；元天元帝與長子天保奴、知院捏怯來、丞相失烈門等數十人逃走。元天元帝打算與丞相咬住在和林會合，行經至土刺河（今土拉河）時，遭遇其部將也速迭兒襲擊，與捏怯來等十六人逃走，元天元帝與咬住、太尉馬兒哈會合，前往投靠人馬眾多的闊闊帖木兒，後來因為大雪三日而不得前進；天元十年十月初三日（1388年11月1日），元天元帝與長子天保奴被也速迭兒派遣的大王火兒忽答孫、王府官孛羅擄獲，最後被用弓絃縊殺；國公老撒、知院捏怯來、丞相失烈門派遣右丞火兒灰、副樞以剌哈、尚書答不歹等人率其部屬三千人投降明朝。也速迭兒奪走了元天元帝的印璽，並廢除大元國號，在哈拉和林自立為汗，稱蒙古可汗，明朝稱韃靼可汗，也不再使用帝號、年號，北元滅亡。
In 1388, the Northern Yuan throne was taken over by Jorightu Khan Yesüder, a descendant of Arik Böke (Tolui's son), with the support of the Oirats. In the following year, one of Uskhal Khan's subjects, Gunashiri, a descendant of Chagatai Khan, founded his own small state called Kara Del in Hami.
The following century saw a succession of Genghisid rulers, many of whom were mere figureheads put on the throne by those warlords who happened to be the most powerful. From the end of the 14th century there appear designations such as "period of small kings" ("Бага хаадын үе").On one side stood the Western Mongols and on the other the Eastern Mongols. While the Oirats drew their khans from the descendants of Ariq Böke and other princes, Arugtai of the Asud supported the old Yuan khans of Kublaid descent. The House of Ogedei also briefly attempted to reunite the Mongols under their rule.
The Mongols eventually split into three main groups: the Oirats in the west, the Uriankhai in northeast, and the Khorchin between the two. The Uriankhai surrendered to the Ming dynasty in the 1390s. The Ming divided them into the Three Guards: Doyin, Tai'nin and Fuyu.
Yuan relations with the Ming dynasty consisted of sporadic bursts of conflict intermingled with periods of peaceful relations and border trade. In 1402, Örüg Temür Khan (Guilichi) abolished the dynastic name Great Yuan; he was however defeated by Öljei Temür Khan (Bunyashiri, r. 1403–1412), the protégé of Tamerlane (d. 1405), in 1403. Most of the Mongol noblemen under Arugtai chingsang sided with Öljei Temur. The Yongle Emperor (r. 1402–1424) issued Öljei Temür an ultimatum demanding his acceptance of the Ming dynasty as a suzerain state. Öljei Temur refused, resulting in the Ming dynasty conducting several campaigns against the Mongols. In 1409, a Ming army of 100,000 entered Mongolia but suffered a defeat against Öljei Temur and Arugtai at the Battle of Kherlen. In the following year, the Yongle Emperor personally led an expedition into Mongolia and defeated the Mongols. After the death of Öljei Temur, the Oirats under their leader Bahamu (Mahmud) (d. 1417) enthroned an Ariq Bökid Delbeg Khan in 1412. Originally the Ming had supported the Oirats in their power struggle with the eastern Mongols, but as the Oirats gained supremacy over them, the Ming withdrew their support. After 1417 Arugtai became dominant again, and Yongle campaigned against him in 1422 and 1423. Bahamu's successor Toghan pushed Arugtai east of the Greater Khingan range in 1433. The Oirats killed him in the west of Baotou the next year. Arugtai's ally Adai Khan (r. 1425–1438) made a last stand in Ejene before he was murdered too.
Toghan died in the very year of his victory over Adai. His son Esen Taishi (r. 1438–1454) brought the Oirats to the height of their power. Under his puppet khans, he drove back Moghulistan and crushed the Uriankhai Three Guards, Kara Del and the Jurchens. In 1449 he defeated a 500,000 strong Ming army with just 20,000 cavalry and captured the Zhengtong Emperor in what came to be known as the Tumu Crisis.However, after this astounding victory, Esen failed to take the Ming capital of Beijing. In the following year a peace was concluded between the two sides and the captive emperor was allowed to return home. After executing the rebellious Tayisung Khan (r. 1433–1453) and his brother Agbarjin in 1453, Esen took the title of not just khan, but also Yuan Emperor.This called widespread dissent among the Genghisids, and in 1455, a series of revolts resulted in Esen's death. His death started the decline of the Oirats, who would not recover until their rise as the Dzungar Khanate in the 17th century.
From Esen's death to 1481 different warlords of the Kharchin, the Belguteids and Ordos Mongols fought over succession and had their Genghisid khans enthroned. The Mongolian chroniclers call some of them the Uyghurs and they might have had some ties with the Hami oasis.During his reign, Manduulun Khan (1475–1478) effectively won over most of the Mongol warlords before he died in 1478.
Manduulun's young khatun Mandukhai proclaimed a seven-year-old boy named Batumongke of Genghisid descent as khan. Mandukhai made persistent efforts to bring the various Mongol tribes under control. The new khan took the title "Dayan" meaning the "Great Yuan". Mandukhai and Dayan Khan defeated the Oirats and the taishis who ruled the Yellow River Mongols. However, one of them killed Dayan Khan's son and revolted when Dayan Khan appointed his son, Ulusbold, as jinong (crown prince) over them. Dayan Khan finally defeated the southwestern Mongols in 1510 with the assistance of his allies, Unebolad wang and the Four Oirats.Making another of his sons jinong, he abolished old-Yuan court titles of taishi, chingsang, pingchan and chiyuan.
From 1495 onward, Dayan exerted pressure on the Ming dynasty, which closed border-trade and killed his envoys. Dayan invaded Ming territory and subjugated the Uriankhai Three Guards, who had previously submitted to the Ming. As a result, the Tümed Mongols ruled in the Ordos region and they gradually extended their domain into northeastern Qinghai.In 1517, Dayan even threatened Beijing itself. Mongol armies raided the Ming dynasty not only in the north but also in the hitherto quiet west. The Ming dynasty lost Kara Del as a protectorate to the Turpan Khanate at the same time. Dayan kept defeating the Ming in battle right up until his death in 1543.At the apogee of Dayan's reign, the Northern Yuan stretched from the Siberian tundra and Lake Baikal in the north, across the Gobi, to the edge of the Yellow River and south of it into the Ordos. The lands extended from the forests of Manchuria in the East past the Altai Mountains and out onto the steppes of Central Asia.
Dayan Khan's reorganization of the Mongols into six Eastern Mongol tümens (literally "ten thousand") and four Oirats tümens had far reaching effects on the development of Mongol society.The six Eastern Mongol tümens were granted to his 11 sons while the four Oirat tümens were ruled by taishi nobles. His youngest son Gersenji Khongtaiji of the Jalayir became the ruler of the Khalkha Mongols, the largest of the six tümens. The tümens functioned both as military units and as tribal administrative bodies who hoped to receive taijis, descended from Dayan Khan. Northern Khalkha people and Uriyankhan were attached to the South Khalkha of eastern Inner Mongolia and Doyin Uriyangkhan of the Three Guards, respectively. After the rebellion of the northern Uriankhai people, they were conquered in 1538 and mostly annexed by the northern Khalkha. However, his decision to divide the six tumens to his sons, or taijis, and local tabunangs-sons in law of the taijis created a decentralized system of Borjigin rule that secured domestic peace and outward expansion for a century. Despite this decentralization there was a remarkable concord within the new Mongol order created by Dayan Khan.
After Dayan Khan's death, the Northern Yuan began falling apart again under the two succeeding khans. By 1540 new regional circles of taijis and local tabunangs (imperial sons-in-law) of the taijis emerged in all the former Dayan Khan's domains. The khagan and the jinong had titular authority over the three right wing tumens. Darayisung Gödeng Khan (r. 1547–1557) had to grant titles of khans to his cousins Altan, ruling the Tumed, and Bayaskhul, ruling the Kharchin.
Under Tümen Jasagtu Khan (r. 1558–92), the realm was unified again with the aid of Altan Khan, Abtai Sain Khan, and Khutughtai Sechen Khongtaiji of Ordos. Jasagtu defeated the Uriankhai and Daghur Mongols and subjugated the Jurchens to the east. Abtai and Sechen brought many of the Oirat tribes under their domination. Altan conquered large parts of Qinghai and left one of his sons in charge there. Jasagtu also tried to unify the Mongols under a new code of law, written in the old Mongol script derived from the Uyghur script. A series of smallpox epidemics and lack of trade forced the Mongols to repeatedly plunder the districts of China. In 1571 the Ming opened trade with the three Right Wing Tumens.
By the end of the 16th century, the Uriankhai Three Guards had lost their existence as a distinct group. Their Fuyu was absorbed by the Khorchin after they had moved to the Nonni River. Two other, Doyin and Tai'nin, were absorbed by the Five Khalkhas.
Although Yuan emperors had previously adopted Buddhism, most Mongols ignored it and remained shamanist in their belief. From 1575, a large-scale conversion to Tibetan Buddhism in the Right Wing Tumens occurred. Jasagtu appointed a Tibetan Buddhist chaplain of the Karmapa order and agreed that Buddhism would henceforth become the state religion of Mongolia. In 1577, Altan and Sechen received the 3rd Dalai Lama, which started the conversion of Tumed and Ordos Mongols to Buddhism. Soon after the Oirats also adopted Buddhism. Numerous Tibetan lamas entered Mongolia to proselytize.
By the reign of Ligdan Khan (r. 1604–1634), the Northern Yuan tumens had ceased to function as a unified entity. Ligdan only controlled the Chahar tumen and the Khalkha and Oirat Mongols no longer obeyed his authority. Ligdan built a new capital in Chahar land known as Chaghan Baishin (White House) and promoted the building of Buddhist monasteries, translation of Tibetan literature, and trade with the Ming dynasty.
In 1616, the Jurchens rose to the forefront of East Asian powers under the reign of Nurhaci. Although sharing many similar characteristics with the Mongols, the Jurchens were not nomads, but a tribal people who had adopted Chinese agricultural practices. Nurhaci had ambitions to conquer the Ming dynasty and sought allies in the Khorchin Mongols, subjects of Ligdan. The princes of Khorchin, Jarud and southern Khalkha Mongols made a formal alliance with the Jurchens from 1612 to 1624.
In response, Ligdan waged war on the Mongol allies of the Jurchens in 1625. The Jurchen-Mongol army defeated Ligdan and forced him back. In the following year, Uuba Noyan of the Khorchin had his younger brother marry one of Nurhaci's daughters, cementing the alliance. Many of the Jurchens married Mongols. Ligdan appointed his own officials over the tumens and formed an elite military band to coerce opposition. In 1628, Ligdan defeated the Khorchins and Jurchen auxiliary at Zhaocheng but fled a large Jurchen punitive expedition. Only Tsogt Taiji (1581–1637) supported the Great Khan whilst other nobles of Khalkha remained neutral and inactive. In 1632, Ambaghai of the Khamag Mongols and his Jurchen Mongol allies defeated the Chahars and captured Ligdan's family. Ligdan lost any authority he had over the non-Chahar tumens. Ligdan died on his way to Qinghai to punish the Gelug order in 1634. His son, Ejei Khan, surrendered to the Qing dynasty and was said to give the Imperial Seal of the Mongols to Qing emperor Hong Taiji the next year (February 1635), ending the Northern Yuan.
After Ligdan Khan's death in 1634, the Mongols formed four Khanates, from west to east:
In 1636, Ambaghai declared himself khagan of all the Mongols but by then, all of Inner Mongolia had already been conquered by the Manchus, and Ambaghai too was under Manchu authority. The son of Ligdan, Ejei Khan, died under mysterious circumstances. His rank was given to his brother Abunai, who refused to attend court with the Manchus. Abunai's rank was then passed on to his son, Burni, who rebelled against the Manchus in 1675, but the uprising was defeated and Burni died in battle.The Qing emperors then placed the Chahar Mongols under their direct rule.
In Outer Mongolia, the Tüsheet Khan Gombodorj retained his independence and suzerainty over the Sechen and Jasagtu khans. However another independent entity known as Altan Khan of the Khalkha emerged in Jasagtu territory. With the loss of Inner Mongolia and the Imperial Mongol Seal, the Mongols had to search for a new source of authority. As a result, in 1639, Gombodorj's brother became the first Jebtsundamba Khutuktu, the spiritual head of the Gelug Buddhists in Mongolia. Gombodorj did his best to maintain peaceful relations with the rising Manchus by sending tribute. He also stopped providing horses to the Ming dynasty. Diplomacy failed after the Manchus defeated the Ming in 1644 and seized Beijing. In 1646, a Mongol noyan rebelled against the Qing but was crushed under overwhelming odds. In 1647, Gombodorj met the Qing in battle with 50,000 cavalry and neither side were able to obtain a decisive victory. Although both sides suffered heavy losses, the Mongol army constituted a larger part of their overall forces than the Qing, signalling that the Mongols no longer had the numbers to directly confront the Qing in battle.
In the mid-17th century, Gombodorj died and was succeeded by his young and inexperienced son Chikhundorj. In 1655, the Qing began interfering in Tusheet affairs by appointing their own lamas in Tusheet territory. Thus Outer Mongolia also gradually fell under Qing control.
Meanwhile, to the west, about 1600–1620 the Oirats united under Kharkhul. In 1635, the Oirats under Kharkhul's son Erdeni Batur formed the Dzungar Khanate. This unification was partly driven by their wars with the Altan Khans. When the Jasagtu Khan Shira lost part of his subjects to the Tüsheet Khan Chikhundorj, Galdan Boshugtu Khan of the Dzungars moved his orda near the Altai Mountains to prepare an attack. Chikhundorj attacked the right wing of the Khalkhas and killed Shira in 1687. In 1688, Galdan dispatched troops under his younger brother Dorji-jav against Chikhundorj but they were eventually defeated and Dorji-jav was killed in battle. Chikhundorj then murdered Degdeehei Mergen Ahai of the Jasagtu Khan who was on the way to Galdan. To avenge the death of his brother, Galdan established friendly relations with the Russians who were already at war with Chikhundorj over territories near Lake Baikal. Armed with Russian firearms, Galdan led 30,000 Dzungar troops into Outer Mongolia in 1688 and defeated Chikhundorj in three days. The Siberian Cossacks, meanwhile, attacked and defeated a Khalkha army of 10,000 near Lake Baikal. After two bloody battles with the Dzungars near Erdene Zuu Monastery and Tomor, Chakhundorji and his brother Jebtsundamba Khutuktu Zanabazar fled across the Gobi Desert to the Qing dynasty and submitted to the Kangxi Emperor.
By 1690, Galdan had control of Outer Mongolia as far as the edge of Manchuria, before turning his attention east towards Beijing. This expansion of the Dzungar state was viewed with worry by the Qing, which led the Kangxi Emperor (Enh-Amgalan khaan-in Mongolian) to block Galdan. Late in the summer of 1690, Galdan crossed the Kherlen River with a force of 20,000 and engaged a Qing army at Battle of Ulan Butung 350 kilometers north of Beijing near the western headwaters of the Liao River. Galdan was forced to retreat and escaped total destruction because the Qing army did not have the supplies or ability to pursue him. In 1696, the Kangxi Emperor led 100,000 troops into Mongolia. Galdan fled from the Kherlen only to be caught by another Qing army attacking from the west. He was defeated in the ensuing Battle of Jao Modo near the upper Tuul River. Galdan's wife, Anu, was killed and the Qing army captured 20,000 cattle and 40,000 sheep. Galdan fled with a small handful of followers. In 1697 he died in the Altai Mountains near Khovd on 4 April. Back in Dzungaria, his nephew Tsewang Rabtan, who had revolted in 1689, was already in control as of 1691. Outer Mongolia was thus incorporated into the Qing Empire, and the Khalkha leaders returned to Outer Mongolia as Qing vassals. A Qing garrison was installed at Ulaanbaatar. The Qing forces occupied Hami but did not advance into Dzungaria. The Dzungars later expanded into Tibet and Kazakhstan, but they too were conquered by the Qing dynasty in 1755, and all resistance was crushed by 1758.