Duan Ye (; died 401) was the first king of Northern Liang of the Sixteen Kingdoms period in Chinese history. He was of Han ethnicity, and was originally a commandery governor of Later Liang, but after Xiongnu generals Juqu Mengxun and Juqu Nancheng () rebelled against Later Liang, Juqu Nancheng persuaded Duan Ye to accept the leadership role of the rebellion. During his reign, the Juqus were powerful, and eventually, in 401, after Duan Ye was tricked by Juqu Mengxun into executing Juqu Nancheng, Juqu Mengxun used this as the excuse to start a coup against Duan Ye, killing him and replacing him as king. Duan Ye was described as a kind but weak ruler who was unable to keep his subjects in check, and who overly trusted witchcraft and magic. Before reign Not much is known about Duan Ye's life before 397. He was from Jingzhao Commandery (京兆, roughly modern Xi'an, Shaanxi), and was probably a low-level official that Former Qin sent to Liang Province (涼州, modern central and western Gansu) after conquering Former Liang in 376. His wife and children remained in Jingzhao. The first historical reference to Duan Ye was in 388, when he was one of the officials under the ruler of Later Liang, Lü Guang, then carrying the title the Duke of Jiuquan. At a feast, Lü Guang and his officials were discussing his administration, when Duan Ye told Lü Guang that he was being overly harsh in his application of laws. Lü Guang, citing the examples of the legalists Wu Qi and Shang Yang, defended his harsh applications. Instead of backing down, Duan Ye pointed out that Wu and Shang both died as a result of their use of laws, and that what Lü Guang was doing was not in accordance of the wishes of the people. Lü Guang solemnly apologized. (However, what this conversation revealed about Duan Ye's own personal philosophy on governance may demonstrate the reasons why he was later ineffective as a ruler.) In 396, when Lü Guang claimed the greater title of Prince of Sanhe, he made Duan Ye one of his ministers. In 397, by which time Lü Guang, then with imperial title, was facing a rebellion from Juqu Mengxun and Juqu Nancheng after listening to false accusations and executing their uncles Juqu Luochou () and Juqu Quzhou (), Duan Ye was the governor of Jiankang Commandery (建康, in