Shingon Buddhist doctrine and teachings arose during the Heian period (794-1185) after a Buddhist monk named Kūkai traveled to China in 804 to study Esoteric Buddhist practices in the city of Xi'an (西安), then called Chang-an, at Azure Dragon Temple (青龍寺) under Huiguo, a favorite student of the legendary Amoghavajra. Kūkai returned to Japan as Huiguo's lineage- and Dharma-successor. Shingon followers usually refer to Kūkai as or , the posthumous name given to him years after his death by Emperor Daigo.