The Bodhisatta was born in Macala under the name of Magha. He spent his time with the heads of the other twenty-nine families in the village, engaged in various forms of social service. The headman, finding his gains diminish, made a false report to the king, who ordered Magha and his friends to be trampled by elephants; but by virtue of their mettā they could not be killed, and thereupon the king showed them great favour. After death they were all born in Tāvatimsa, with Magha as Sakka.
Three of Magha's wives - Sudhammā, Cittā and Nandā - who had persuaded him to let them share in his good work, were born as Sakka's handmaidens. But Sujātā, who had taken no part in their activities, received no such honour. At that time the Asuras shared Tāvatimsa with the Devas, but one day they got drunk and were hurled down to the foot of Sineru. They therefore declared war on the Devas, and during one of their fierce battles Sakka was defeated and fled over the sea in his chariot Vejayanta. When he came to Simbalivana, the chariot felled down the trees there, and the young Garulas were hurled into the sea. Hearing their cries of agony, Sakka made his driver, Mātali, turn the chariot and go back. The Asuras, seeing him return, thought it was another Sakka coming with reinforcements, and fled in terror. The Vejayanta-pāsāda rose from the earth, and Sakka lived in it, having fortified his city with a fivefold guard.
The story was told in reference to a monk who had drunk water without first straining it, because his friend, with whom he was travelling and with whom he had fallen out, had the only strainer available. Mātali is identified with Ananda (J.i.198ff; with the introductory story cp. Vin.ii.118).
In the version given in the Dhammapada Commentary (i.263ff; see also SA.i.260f; DA.iii.710ff; and SNA.ii.484f; according to these accounts Sakka was helped by not 29 but 33 others), the story of Magha is related in response to a question asked of the Buddha by the Licchavi Mahāli. The reason given for Sakka's flight in the Vejayantaratha also differs. According to this account, when Sujātā (q.v.) was reborn as the daughter of Vepacitti and the time came for her to choose a husband, Sakka went to the assembly in the guise of an aged Asura and was chosen by Sujātā. Sakka thereupon revealed himself and fled with his bride in the chariot, the Asuras in full chase.
See also Kulāvaka Sutta.