하안
He Gui was born in 858, during the reign of Emperor Xuānzong of Tang. It is known that he was from Puyang, but all that is known about his family were the names of several male-line ancestors — great-grandfather He Yan (), grandfather He Hua (), and father He Zhongyuan (). It was said that He Gui was ambitious in his youth, and became a soldier during the late Tang Dynasty disturbance, becoming an officer under Zhu Xuan the prefect of Pu Prefecture () in modern Heze, Shandong.