was overthrown in 902 and three dynasties followed in quick succession before Duan Siping seized power in 937, establishing himself at Dali. The Duan clan professed to have Han ancestry. The Yuan dynasty records said the Duan family came from Wuwei in Gansu.
Dali's relationship with the Song was cordial throughout its entire existence. Dali congratulated the Song dynasty on the conquest of Later Shu in 965 and voluntarily established tribute relations in 982. It was however essentially an independent state. At times the Song even declined offers of tribute. The Song founder Song Taizu declared all land south of the Dadu River to be Dali territory and did not desire to pursue any further claims to avoid the Tang dynasty's disastrous efforts against Nanzhao. Dali's primary importance to the Song dynasty was its horses, which were highly prized and sought after as military assets, especially after the fall of the Northern Song. They were described by a Song official in the following passage:
Dazhong Kingdom (1094-1096)
In 1094, the former prime minister Gao Shengtai forced King Duan Zhengming to relinquish the throne to him and renamed the Dali Kingdom to "Dazhong Kingdom". Gao Shengtai ruled briefly until his death in 1096, after which the throne was returned to the Duan family. Duan Zhengming's younger brother, Duan Zhengchun, became the new ruler and restored the kingdom's former name.
Fall
In 1252 Möngke Khan placed his brother Kublai in charge of invading Dali. In 1253 Kublai's army crossed the Jinsha River and received the surrender of Duan Xingzhi, who presented to Möngke in 1256 maps of Yunnan. Duan Xingzhi of Dali was enfeoffed as Maharaja by Kublai Khan, and the Duan royal family continued to hold the title of Maharaja in Yunnan as vassals to the Mongols under the supervision of Mongolian imperial princes and Muslim governors. The Duan family reigned in Dali while the governors served in Kunming. After the Ming conquest of Yunnan, The Duan royals were scattered in various distant areas of China by the Hongwu Emperor.
Yunnan under the Mongols
The Duan family governed Yunnan's various indigenous peoples for eleven generations until the end of Mongol rule. They willingly contributed soldiers to the Mongol campaign against the Song dynasty. In 1271, they aided the Yuan dynasty in putting down a Mongol rebellion in Yunnan. In 1274, Ajall Shams al-Din Omar was assigned by Kublai to stabilize Yunnan. He instituted a native chieftain system that came to be known as tusi which assigned ranks and posts to native chieftains. Under this institution of "rule based on native customs" the locals retained much of their autonomy with the exception of three obligations. One, they would provide surrendered troops to the Yuan government. Two, local chieftains would provide tribute to the Yuan court. Three, they would follow the rules of appointment, succession, promotion, degradation, reward, and punishment of native chieftains created by the Yuan court. Yuan rule also introduced a significant Muslim influence into Yunnan. The King of Dali Duan Gong was married to the Mongol Borjigin princess Agai, daughter of the Yuan dynasty Mongol Prince of Liang, Basalawarmi. They had a son and a daughter, Duan Sengnu. their children were also called Duan Qiangna amd Duan Bao. Duan Sengnu raised Duan Bao to take revenge against Basalawarmi for the killing of Duan Gong. A play was made based on these events. According to Yuan documents, the Duan family were originally Han Chinese from Wuwei commamdery, Gansu. Other Duan families also originated from Wuwei.
Conquest by Ming
In 1381, the Ming dynasty dispatched 300,000 troops to crush the Yuan remnants in Yunnan. The House of Duan, who helped the Mongols against a Red Turban Rebellion attack from Sichuan, also fought against the Ming army. The ruler Duan Gong refused to surrender by writing to Fu Youde, making it clear that Dali could only be a tributary to the Ming. Fu Youdei attacked and crushed Duan Gong's realm after a fierce battle. The Duan brothers were taken captive and escorted back to the Ming capital.
Religion
A version of Buddhism known as Azhali existed in Yunnan since the 9th century. The last king of Nanzhao established Buddhism as a state religion and many Dali kings continued the tradition. Ten of Dali's 22 kings retired to become monks.
Governance
Under the influence of Chinese officials present from early times, the Dali elite used Chinese script supplemented by Bai characters that were constructed based on Chinese characters. The Dali court granted hereditary fiefs to pre-existing clan chiefs to win over support, as well as autonomous military divisions. Similarly to the Nanzhao military, the Dali military consisted of a standing army, townsfolk peasant-soldiers and indigenous militia.