[2] According to the shrine's legend, when Emperor Nintoku divided the ancient province of Keno at the Kinugawa River into Kamitsukeno (上毛野) and Shimotsukeno (下毛野) (later Kōzuke and Shimotsuke) in the 5th century, he appointed Narawake-no-kimi as the kuni no miyatsuko of Shimotsukeno.
This Narawake-no-kimi built a shrine to honor his great-grandfather Prince Toyokiirihiko as ujigami of the region.
Per the Nihon Shoki, Prince Toyokiirihiko had been dispatched by his father Emperor Sujin to rule over Keno in response to a dream in which he had climbed Mount Miwa and swung a spear and a sword to the east.
As Prince Toyokiirihiko excelled in the martial arts, the shrine was patronized by famous military commanders throughout its history.
Fujiwara Hidesato was able to defeat Taira no Masakado in the Jōhei-Tengyō Rebellion using a magic sword received from this shrine.