The Real Reason Kamikaze Pilots Wore Flying Helmets
In World War II, the United States and its allies were introduced to a form of warfare that would be unthinkable in the West: kamikaze (literally, "divine wind") pilots would load their planes with weapons and then fly them into their targets on suicide missions. According to Motoharu Okamura, "crash-dive attacks with our planes" were the only way to "swing the war in our favor" (via National Geographic). Kamikaze missions resulted in the loss of 3,000 Japanese lives and 7,000 casualties (deaths and injuries combined) among American fighters and their allies over the course of World War II.
Curiously, the kamikaze pilots, though on missions that were undoubtedly going to end their lives, still wore helmets (although officially, they didn't wear helmets but rather leather headcovers with ear flaps). As it turns out, however, there were plenty of good reasons to put protective headgear on a kamikaze pilot, even if their mission was doomed to end in his death.
Flying military aircraft is tough on the head
Even if their mission is guaranteed to end in his death, a kamikaze pilot still needs their headgear while carrying it out. That's because, among other things, the head of a pilot in a military aircraft — whether a modern one or a Japanese Zero — is going to get knocked about against the windows of the vehicle repeatedly during the flight. Further, as Mental Floss explains, sometimes the pilots would need to open their canopies to see better, and the ear flaps would offer some measure of protection against the deafening noise of the wind and the engine. Finally, as History of Yesterday notes, not all kamikaze missions were carried out to completion — some were aborted due to weather or other concerns. Indeed, one of the few kamikaze pilots to survive the war was Kenichiro Oonuki, who had to abort his mission and land his plane due to engine trouble.
Long story short, kamikaze pilots wore "helmets" (or, more accurately, protective headgear) in order to complete the mission, not necessarily to survive it.