Tian Ji'an (田季安) (781 or 782 – September 21, 812), courtesy name Kui (夔), formally the Prince of Yanmen (雁門王), was a general of the Tang Dynasty, who, as military governor (Jiedushi), ruled Weibo Circuit (魏博, headquartered in modern Handan, Hebei) in a de facto independent manner from the imperial regime.
Tian Ji'an was born in 781 or 782, during the reign of Emperor Dezong of Tang. At that time, his father Tian Xu was an officer under Tian Xu's cousin Tian Yue, the military governor of Weibo Circuit, who governed the circuit semi-independently from the imperial regime. (Tian Xu's father Tian Chengsi had been the first military governor of Weibo, but chose Tian Yue to be his successor rather than any of his sons.) Tian Ji'an was Tian Xu's third son, and was born of a mother of lowly birth. After Tian Xu assassinated Tian Yue and succeeded him in 784, Emperor Dezong gave Tian Xu his sister Princess Jiacheng in marriage in 785. As she had no son of her own, she adopted Tian Ji'an as her son. He was thus made the deputy military governor and Tian Xu's designated successor. When Tian Xu died suddenly in 796, the Weibo soldiers supported Tian Ji'an as acting military governor, and Emperor Dezong made him military governor later in the year. Tian Ji'an also inherited Tian Xu's title as Prince of Yanmen.
In 806, Tian Ji'an was further given the honorary chancellor designation of Tong Zhongshu Menxia Pingzhangshi (同中書門下平章事). It was said that in Tian's youth, his behavior was curbed in by Princess Jiacheng's sternness, and that while he was not capable, he followed the rites and the laws. After Princess Jiacheng died, however, he lost self-control, and he spent his time on polo, hunting, and pleasure.
In 809, after the death of Wang Shizhen the military governor of neighboring Chengde Circuit (成德, headquartered in modern Shijiazhuang, Hebei), Emperor Dezong's grandson Emperor Xianzong, then emperor, was taking a harder line against the circuits acting as semi-independent states, and for months he refused to approve the succession of Wang Shizhen's son Wang Chengzong. Emperor Xianzong finally agreed after Wang Chengzong agreed to allow two of Chengde's prefectures, De (德州, in modern Dezhou, Shandong) and Di (棣州, in modern Binzhou, Shandong) be separated into a different circuit under imperial control, to be named Baoxin Circuit (保信, to be headquartered at De Prefecture). He made Xue Changchao (薛昌朝) the prefect of De Prefecture, whose wife was from the Wang clan, the military governor of the new circuit. However, when Tian received news of this in advance of the news arriving at Chengde, he informed Wang Chengzong that Xue had betrayed him. In response, Wang Chengzong had Xue arrested and refused to submit the two prefectures.