Before starting the story do you know why is it celebrated on the eight-day or Ashtami? It is believed that Krishna is the eighth child of his mother, Devaki so, Krishna Janmashtami is celebrated on the eighth day.
According to Hindu mythology, the evil king Kansa ruled Mathura. To extend his empire he married his sister with Vasudeva, the Yadu king. After the marriage, Kansa decided to shower the newlyweds with lavish gifts because he wanted to gain the trust of Vasudeva. But heaven has another plan for them. When he takes the reins of the nuptial chariot, a voice from heaven booms that his evil ways will come to an end by his sister’s 8th child.
After knowing about his prophecy, Kansa sends his sister and her husband Vasudeva in a prison. Actually, Kansa wanted to kill Devaki but Vasudeva promised him that he will give all his 8 children in the hands of Kansa if he would spare Devaki’s life.
Kansa agreed and one by one he killed all the six children who were born to the couple. For the 7th time when Devaki got pregnant interesting things started happening. Through divine intervention, the seventh child of Devaki is transferred from her womb to the womb of Rohini, Vasudeva’s first wife, and in this way, Devaki’s and Vasudeva’s seventh child was safely born.
When Devaki was pregnant again, Kansa again was anxious to kill the couple’s child but God’s wish was different. Krishna was in fact the eighth child of Devaki and also an avatar of Lord Vishnu.
When Devaki was going into labour pain, Vishnu appears in her prison cell and informs Vasudeva that his eighth child is an incarnation of himself that is Lord Vishnu and will make an end to the kingdom of Kansa.
That night was dark with thunderstorms and lightning; Vishnu destroys all the locks and puts the guards to sleep. He also gave Vishnu instructions on what he has to do and then suddenly Lord Vishnu disappears.
Vasudeva as per the instructions left the palace by carrying a wicker basket containing his divine son. He crossed the Yamuna into the village of Gokul and exchanges the baby with the newborn baby girl of Gokul’s head Nanda and his wife Yashoda.
In this way, Krishna grew up in Gokul and finally killed his uncle, Kansa.