“Much that is kindly and gracious in the life of the Japanese today,” wrote the eminent historian George Bailey Sansom in 1931, “can be traced to those sentiments which caused their remote ancestors to ascribe divinity not only to the powerful and awe-inspiring … but also to the lovely and pleasant.”

Gods come in many shapes and forms, endowed with myriad attributes. There are powerful gods and powerless gods, friendly and malicious gods, life-giving and life-destroying gods, gods who demand animal and human sacrifice and gods who wouldn’t dream of such a thing.

The untamed primitive imagination is sensitive to its environment as ours can never be again. The founding environments of Western civilization — the deserts of Mesopotamia, the stony soil and craggy mountains of Greece — were harsh and unforgiving. They bred harsh and unforgiving gods. The contrast to Japan is stark. Japan’s gentle climate and yielding landscape bred “kindly and gracious” gods, whose people, if Sansom is correct, take after them.

Pre-modern Japanese history is striking in its relative lack of cruelty. The word “relative” is important. Any 2,000-year span will contain horrific episodes. Three that stand out, under rulers who might well be described as psychopathic in their relish of other people’s suffering, are a brief reign of terror under Shogun Ashikaga Yoshinori (ruled 1429-1441), which ended with his murder; the brutal unification of the fractured nation begun in the mid-16th century by warlord Oda Nobunaga (1534-1582), who was also murdered; and the anti-Christian genocide of the early 17th century, whose tortures ran the gamut from crucifixion to burning, boiling and burying alive. It may or may not be significant — but probably is — that the latter two instances occurred after Japan had come under Western influence.

This is not to say that Japanese history is otherwise pacific. But at times, and sometimes for very extended times, it is: the peace of the Heian Period (794-1185) lasted four centuries; that of the Edo Period (1603-1868) more than two; and if we broaden our scope to include prehistory, the Jomon Period (circa 14,000 BC-circa 300 BC) may well represent the longest peace ever, anywhere.

War and slaughter made their inroads all the same, glorified with such poetic and martial fervor as to leave even Western bellicosity in the shade. But cruelty and violence are not synonymous. Violence there was, in abundance. Cruelty, though, in the sense of sadism, so conspicuous in history and myth elsewhere, tarnishes Japan’s history and mythology relatively little.

Japan’s gods and goddesses are powerful but not power-mad, capricious but not vindictive; to be worshipped more in joy than in fear. They are not monstrous, awesome, omnipotent or terrifying, as are other gods we know: Mesopotamian, Egyptian, Biblical. Japan’s birth is a love story. Two young deities — a boy-god and a girl-god — discover each other as human adolescents do, shyly and awkwardly at first, then with growing confidence. It’s a beautiful story, very different from the Biblical creation or the Greek poet Hesiod’s Theogony, circa 9th century BC: “And Night bore hateful Doom and black Fate, and Death, and Sleep and the brood of Dreams … .”

Japan’s myriad gods wage no wars, launch no mass slaughters, drink no blood, are mild even in their anger, and laugh. Imagine the Biblical God laughing — or Greece’s pre-Olympian Titans — “strong, hulking creatures,” says Hesiod, “that beggar description. … A hundred hands stuck out of their shoulders, grotesque, and 50 heads grew on each stumpy neck.” What in Japanese mythology compares to the castration of a monstrous Titan by his scarcely less monstrous son; or the wrathful Biblical God’s mankind-destroying flood, or His destruction of whole cities by “brimstone and fire”? The most violent episode in Japanese mythology is the rampage through the Sun Goddess’ rice fields by her unruly brother Susano’o, the Storm God. Amaterasu, the Sun Goddess, hides in a cave, from which she is lured out by — of all things! — a rollicking erotic dance staged by the other deities. Drawn by their laughter, she pokes her head out to see what’s happening. Light returns to the world, never to vanish again.

The Christian religion enjoins us to love our enemies. It’s an injunction much preached and little heeded. If we loved our enemies they’d be our friends, not our enemies. Japanese morality has no comparable ethic, and Japanese conduct down the ages is refreshingly free of the hypocrisy that inevitably arises from religious requirements beyond the reach of all but the saintly few.

Japanese warriors didn’t love their enemies. The remarkable thing is how little they hated them. They killed them and were killed by them, but the attitude toward death was such that, generally speaking, the infliction of it was not in the spirit of hatred, more in that of human beings engaged in the highest human activity there is, so that what looks like wanton slaughter from a pacifist point of view is to the combatants a manifestation of life at its highest peak of intensity.

You didn’t hate your enemy, or impute evil to him. An enemy was a kind of relative, a brother-in-arms, and the way you expressed the relationship was by killing him or being killed by him. The customary collection of and gloating over enemy heads seems to belie the civilized rituality that that implies. An old woman named O-An, looking back in 17th-century peace on 16th-century wars she’d experienced as a child — her recollections, written down by unknown scribes, enjoyed great popularity throughout the Edo Period — tells awestruck children who love to listen to her: “The severed heads taken by our side were collected in the castle keep. We attached name tags to all of them, to keep track of whose they were. … We weren’t frightened of the heads. We would lie down and sleep with blood-stinking heads all around us.”

Horrible enough — but the mutilation of dead bodies has this to be said for it: It is better than the mutilation of live ones.

Michael Hoffman is the author of “In the Land of the Kami: A Journey into the Hearts of Japan” and “Other Worlds.”