Emperor Kanmu established it as the capital in 794, moving the Imperial Court there from nearby Nagaoka-kyō at the recommendation of his advisor Wake no Kiyomaro and marking the beginning of the Heian period of Japanese history.
[1] According to modern scholarship, the city is thought to have been modelled after the urban planning for the Tang dynasty Chinese capital of Chang'an (modern-day Xi'an).
Heian-kyō was built in what is now the central part of Kyoto city covering an area spanning the Kadono (葛野郡, Kadono-gun) and Otagi Districts (愛宕郡, Otagi-gun) of Yamashiro Province.
However, only 9 years later in January 793 AD, Emperor Kammu assembled his retainers and announced another relocation of the capital (for the reason see the entry on Nagaoka-kyō.)
It is said that the Emperor Kammu had previously looked out on Kadono from the Shōgun Tsuka in Higashiyama Ward of Kyoto City, deciding then that it was a suitable location for the capital.
Emperor Kammu's words are recorded in the Nihon Kiryaku as follows: "Kadono has beautiful mountains and rivers as well as good transport links by sea and land making it convenient for people to assemble there from all four corners of the country."
Similar to the previous capital of Nagaoka-kyō, the construction of Buddhist temples in Heian-kyō was formally forbidden, with the sole exception of the East and West temples, with the thought that their power might protect the city from natural disaster and disease, and priests such as Kūkai were welcomed, being able men, well versed in Buddhist scripture and with no interest in political power.
The land of the Right Capital overlapped the wetlands formed by the Katsura River and even by the 9th century little progress had been made in developing the area.
By the 10th century when the Ritsuryō system was almost at an end, the district had become so dilapidated that it began to be used as farmland, something which had previously been forbidden within the city limits.
With the advent of the Kanto centered Kamakura and Edo shogunates, Heian-kyō began to lose its significance as a seat of power.
The greatest decline was during the Muromachi and Sengoku periods when almost half the city was burnt to the ground during the Ōnin war.
However, at the direction of the Emperor Meiji, the imperial residences have been preserved and the takamikura (高御座)—a special throne whose location traditionally marked the seat of the emperor—remains at the palace in Kyoto.
The gates of the Daidairi are marked in Japanese Kanji in the above grid, below are the romanization of said gate names alongside the kanji: Below is a 1696 map of Kyoto, known as Genroku 9 Kyoto Daizu (元禄九年京都大絵図) Archived 2016-10-08 at the Wayback Machine held by the International Research Center for Japanese Studies (Nichibunken).