Wen Tingyun (born 812, Qi county, Shanxi province, China—died 866, China) was a Chinese lyric poet of the late Tang dynasty who helped to establish a new style of versification associated with the ci form, which flourished in the subsequent Song dynasty (960–1279).
Derived from ballads performed by professional female singers in the wineshops and brothels of the day, ci borrowed metres from existing musical scores and were themselves sung to instrumental accompaniment. Wen, whose aristocratic birth allowed him a life of leisure, frequented the urban amusement quarters to collect ballads as models for his own love lyrics. Admired for the delicate sensuality of his verse and his skill at evoking feminine sensibility, Wen was chosen as the lead poet in the first major anthology of ci poetry, the Huajianji (Among the Flowers), compiled by Zhao Chongzuo in 940 to popularize the new genre.