The traditional account of bon odori begins with Maudgalyayana, in Japanese Mokuren, one of the principal disciples of the Buddha. In the story told in the Yulanpen or Ullambana Sutra, he uses his newly acquired supernatural sight to look for his dead mother and finds her suffering among the hungry ghosts, unable to eat. The Buddha tells him he cannot free her alone and instructs him to make offerings to the assembled monastic community at the close of the summer retreat. He does, his mother is released, and in his relief he dances.
That story gives the season its name, its date and its dance in one movement, and it is why Obon falls in the seventh month, around the middle of August in most of Japan and the middle of July in others where the older calendar reckoning was kept. The observance was established in Japan by the seventh century and had become general by the medieval period, when it absorbed local ancestral customs that had nothing to do with the sutra. What resulted is a season with two layers that Japanese practice has never felt the need to separate: a Buddhist memorial rite performed at the temple and in front of the household altar, and a village dance in the open air that anybody can join.