The first appearance of the word castle in literature is Mizuki (water fortress) built by Emperor Tenchi in 664, and plenty of castles, including ones not found in literature, were built in the area from the northern part of Kyushu to the coasts of the Seto Inland Sea in this age.
城の文献上の初見は、664年に天智天皇が築いた水城（みずき）で、この時代には文献に見えないものも含め多数の城が九州北部から瀬戸内海沿岸に作られた。