Duan Wenchang (Chinese: 段文昌; 773 – April 1, 835), courtesy name Moqing (墨卿), alternative name Jingchu (景初), formally the Duke of Zouping (鄒平公), was an official of the Chinese dynasty Tang Dynasty, serving as a chancellor during the reign of Emperor Muzong.
Duan Wenchang was born in 773, during the reign of Emperor Daizong. His great-great-grandfather Duan Zhixuan (段志玄) was one of the major contributors to the establishment of Tang rule, and thus received two great honors — being buried near the tomb of Emperor Taizong and having his portrait being one of the 24 Portraits at Lingyan Pavilion. His great-grandfather Duan Guan (段瓘) served as a county magistrate; his grandfather Duan Huaichang (段懷昶) served as a prefectural military advisor; and his father Duan E (段諤) served as a prefectural prefect.
By Duan Wenchang's time, his family, although originally from Qi Prefecture (齊州, in modern Zibo, Shandong), had been living at Jing Prefecture (荊州, in modern Jingzhou, Hubei). Duan Wenchang, in his youth, became known for his integrity and righteousness, and while this was known by the military governor (Jiedushi) of the region, Jingnan Circuit (荊南, headquartered in modern Jingzhou), Pei Zhou (裴冑) and Pei respected him for this, Pei did not invite him to serve on staff. However, Wei Gao the military governor of Xichuan Circuit (西川, headquartered in modern Chengdu, Sichuan) heard about him and invited him to serve on staff. While the future chancellor Li Jifu was serving as the prefect of Zhong Prefecture (忠州, in modern Chongqing), a part of Xichuan Circuit, he and Duan had correspondences.