The Guardian Deity of Matsumoto Castle
The small shrine located inside the roof of the Great Keep is dedicated to the deity Nijūroku-yashin, or “deity of the twenty-sixth night.” Nijūroku-yashin is said to serve as guardian of the castle.
A legend surrounding the deity describes an event on the twenty-sixth day of the first month of 1618. A samurai named Kawai Hachirōsaburō was guarding the residence in the main bailey late at night. Just as the moon appeared from behind the mountains, he heard an unfamiliar voice calling his name. When he turned to look for the intruder, a woman in flowing scarlet hakama trousers appeared before him. Kawai immediately dropped to his hands and knees in awe.
The woman handed him a brocade pouch and told him that his lord’s household would prosper if a monthly offering was made of rice measuring 3 goku, 3 to, 3 shō, 3 gō, and shaku (roughly 500 kilograms in total). She also warned him that the pouch must not be opened, and then she vanished. The following morning, Kawai reported this occurrence to the lord of the castle, Toda Yasunaga (1562–1633). It is said that thereafter offerings were made on the twenty-sixth night of each month until the Toda family gave up control of the castle in 1868.
The worship of Nijūroku-yashin might be connected to a folk religious practice that was popular in the Kanto region. Believers would stay up on the twenty-sixth night of every month, praying for the appearance of Amida Buddha and his attendants.