Hanzo was born as the son of Hattori Yasunaga, a minor samurai in the service of the Matsudaira (later Tokugawa) clan. He would later earn the nickname Oni no Hanz0 because of the fearless tactics he displayed in his operations; his other nickname was Yari no Hanzo
Though Hanz? was born and raised in Mikawa Province, he often returned to Iga Province, home of the Hattori family. He fought his first battle at the age of 16 (a night-time attack on Udo castle and went on to serve with distinction at the battles of Anegawa (1570) and Mikatagahara (1572). His most valuable contribution came in 1582 following Oda Nobunaga's death, when he led the future shogun Tokugawa Ieyasu to safety in Mikawa Province across Iga territory with the help of remnants of the local Iga ninja clans as well as their one-time rivals in Koga.
Hanz? was known as an expert tactician and a master of spear fighting. Various magical tricks such as disappearing and appearing elsewhere, psychokinesis and precognition were also supposedly attributed to him. Historical sources say he actually died in 1596 at the age of 55. According to a popular legend, the ninja of F?ma Kotar? killed Hanz? in sea combat during their raid against the Tokugawa forces in the Inland Sea
Hattori Hanz? was succeeded by his 18-year-old son, whose name was also Masanari, though written with different kanji. He was given the title of Iwami no Kami and his men would act as guards of Edo Castle, the headquarters of the government of united Japan. There have been also as many as three other Hattori Hanz?s leading his clan at one point or another (including one before him).
To this day, artifacts of Hanz?'s legacy remain; the Tokyo Imperial Palace (formerly the shogun's palace) still has a gate called Hanz?'s Gate (Hanz?mon), and the Hanz?mon subway line which runs from central Tokyo to the southwestern suburbs is named after the gate. Hanz?’s remains now rest in the Sainen-ji temple cemetery in Yotsuya, Tokyo. The temple also holds his favorite spear and his ceremonial battle helmet. The spear, donated to the temple by Hanz? as a votive offering, was originally given to him by Ieyasu and suffered damage during the bombing of Tokyo in 1945.