This festival originated during an epidemic in 869 as part of a purification ritual (goryo-e) to appease the gods thought to cause fire, floods and earthquakes.
In 869, when people were suffering from a plague attributed to the rampaging deity Gozu Tennō (牛頭天王), Emperor Seiwa ordered prayers to the god of the Yasaka Shrine, Susanoo-no-Mikoto.
Sixty-six stylized and decorated halberds, one for each of the traditional provinces of Japan, were prepared and erected at Shinsen-en, a garden, along with portable shrines (mikoshi) from Yasaka Shrine.
This practice was repeated wherever an outbreak of plague occurred.
In 970, the festival became an annual event and it has since seldom failed to take place.
During  the Ashikaga shogunate, late 15th and early 16th century, the festival was halted.
Later in the 16th century it was revived by Nobunaga .Over time the increasingly powerful and influential merchant class made the festival more elaborate and, by the Edo period (1603–1868), it was using the parade to brandish its wealth.

Smaller floats lost or damaged over the centuries have been restored, and the weavers of the Nishijin area offer new tapestries to replace destroyed ones.
When they are not in use, the floats and regalia are kept in special storehouses throughout the central merchant district of Kyoto.

The festival serves as an important setting in Yasunari Kawabata's novel, The Old Capital in which he describes the festival, along with the Festival of Ages and the Aoi Festival, as "the 'three great festivals' of the old capital".
This festival originated during an epidemic in 869 as part of a purification ritual (goryo-e) to appease the gods thought to cause fire, floods and earthquakes. In 869, when people were suffering from a plague attributed to the rampaging deity Gozu Tennō (牛頭天王), Emperor Seiwa ordered prayers to the god of the Yasaka Shrine, Susanoo-no-Mikoto. Sixty-six stylized and decorated halberds, one for each of the traditional provinces of Japan, were prepared and erected at Shinsen-en, a garden, along with portable shrines (mikoshi) from Yasaka Shrine. This practice was repeated wherever an outbreak of plague occurred. In 970, the festival became an annual event and it has since seldom failed to take place. During  the Ashikaga shogunate, late 15th and early 16th century, the festival was halted. Later in the 16th century it was revived by Nobunaga .Over time the increasingly powerful and influential merchant class made the festival more elaborate and, by the Edo period (1603–1868), it was using the parade to brandish its wealth.
Smaller floats lost or damaged over the centuries have been restored, and the weavers of the Nishijin area offer new tapestries to replace destroyed ones. When they are not in use, the floats and regalia are kept in special storehouses throughout the central merchant district of Kyoto.
The festival serves as an important setting in Yasunari Kawabata's novel, The Old Capital in which he describes the festival, along with the Festival of Ages and the Aoi Festival, as "the 'three great festivals' of the old capital".
Gion Matsuri