Once upon a time, Lord Indra was going to Kailash mountain to meet Lord Shiva along with Sage Brihaspati. Lord Shiva came to know about their arrival and he wanted to test his devotion towaards him. Lord Shiva met them on their way disguised as a hermit. Indra did not recognize Lord Shiva. Indra inquired as to who he was and where he lived. Lord Shiva sat quietly without replying to his question. Indra asked him again and again, but Lord Shiva did not reply. Indra became angry and tried to attack Lord Shiva with his Vajra (sword).
Lord Shiva paralyzed the hands of Indra by his divine power. Shiva's eyes turned to red with anger, which made Indra frightened. Sage Brihaspati was able to recognize that hermit was none other than Lord Shiva. He prayed Lord Shiva and requested him to pardon Indra. Lord Shiva became pleased and diverted the power of his radiant eyes to the sea. Lord Shiva went back to Kailash mountain. Indra and sage Brihaspati returned back to their own places.
The effulgence, which had been divided from Lord Shiva into the sea resulted into the manifestation of a small child. The child was crying so loudly that fear was created everywhere. The deities and the sages went to Lord Brahma to and he assured them to find out the reason. Lord Brahma went to the seashore. The sea put the child in his lap and asked him about the name of that child and his future. Meanwhile the child pressed Lord Brahma's neck with such power that tears rolled down from his eyes. For this reason he named the child as Jalandhar. Lord Brahma said to the sea that the child will become the king of the demons and no deity would be able to kill him except Shiva. After Lord Brahma returned to his abode, the sea took that child to his home and brought up the child with care and love.
Jalandhar grew up and married Vrinda, the daughter of Kalnemi. Later he became the king of the demons. One day Sage Bhrigu came to meet Jalandhar. Jalandhar asked him as to who severed the head of Rahu. Sage Bhrigu told him about Hiranyakashipu who was the maternal uncle of Rahu. Sage Bhrigu also told him about Virochana - the son of the mighty king Bali. He also narrated the story of churning of ocean and how ambrosia emerged from the churning of the ocean. He told him how Rahu's head was severed by Lord Vishnu while Rahu was sitting among the deities when ambrosia was being distributed to all the deities.
Jalandhar became angry after hearing this tale. He sent one of his messengers named Ghasmar to Indra to ask him why he took all the wealth of his father (sea) which emerged during the churning of the sea. Jalandhar also instructed Ghasmar to warn Indra about the dire consequences unless he takes his refuge. Indra sent back Ghasmar without any specific assurance and this made Jalandhar more angry and he attacked Indra with his army.
A fierce battle was fought between the armies of Jalandhar and dieties and many warriors died from both the sides. Shukracharya, the guru of the demons brought back the dead warriors from the demon side back to life by his mritasanjivani vidya. Sage Brihaspati brought back the dead warriors from the deities side back to life with the help of medicinal herbs. When Shukracharya saw that sage Brihaspati was also successfully making the dead deities alive, he instructed Jalandhar to submerge the Drongiri mountain into the sea so that it becomes impossible for Brihaspati to get the medicinal herbs by the help of which he made the dead deities alive.
Jalandhar submerged the Drongiri mountain into the sea and the deities became demoralized and fled from the battlefield and Jalandhar captured the Swargaloka. Then deities went to Lord Vishnu and asked his help. Lord Vishnu agreed to help them, but Goddess Lakshmi considered Jalandhar as her brother because both of them originated from the sea. She asked Lord Vishnu not to kill Jalandhar. Lord Vishnu promised to her that he will not kill Jalandhar and he went to fight a battle against Jalandhar. A fierce battle was fought between Lord Vishnu and Jalandhar, which remained indecisive till the end. Lord Vishnu became very much impressed by the valiance of Jalandhar and asked him to demand any boon he liked.
Jalandhar requested him to make Ksheersagar (sea of milk) as the abode of Jalandhar along with his sister Goddess Lakshmi. Lord Vishnu agreed to fulfill his wish and started living in the Ksheersagar along with his consort Lakshmi. Being undefeated even by Lord Vishnu, Jalandhar became the ruler of all the three worlds. All his subjects were satisfied by his virtuous rule except the deities.
Then deities prayed Lord Shiva to seek his help in defeating Jalandhar. According to the wish of lord Shiva, Sage Narada came to meet the deities. The deities narrated their woeful tales to him. Sage Narada went to meet Jalandhar and received a grand reception by Jalandhar, which pleased him very much. Narada praised the splendours and prosperity of Jalandhar but said that it was nothing in comparison to Shiva's splendours. Narada told him that inspite of all his authority and splendours, his prosperity was still incomplete, as he did not have a consort. Jalandhar asked him where could he find his consort.
Narada told Jalandhar to make Parvati as his consort and Jalandhar fell into Narada's trap. He sent Rahu to Lord Shiva with a proposal to part with Parvati. Rahu went to Lord Shiva and demanded Parvati, which made Lord Shiva very angry. His anger resulted into the creation of a ferocious creature, which ran towards Rahu to devour him. Rahu had no option but to take the refuge of Lord Shiva. Lord Shiva protected the life of Rahu. The hungry creature asked Lord Shiva as to what should he eat to satisfy his hunger. Lord Shiva instructed him to devour his own limbs. The creative followed his instructions and devoured his limbs. Lord Shiva was very pleased by his sense of obedience. He named that creature of his palace. He also blessed him saying that he too would be worshipped along with him.
Rahu went back to Jalandhar and narrated the whole thing to him. Jalandhar attacked Kailash mountain with his army. A fierce battle was fought between the Shiva-ganas and the demons. When Jalandhar realized that Lord Shiva had begun to dominate the battle he created beautiful Apsaras and Gandharvas by his magical powers to divert the attention of Lord Shiva and his ganas. Lord Shiva and his ganas became enchanted by the beauty of the apsaras. They stopped fighting and started watching their dance and music.
In the meantime Jalandhar went to Parvati disguised as Lord Shiva, but was recognized by her. Being enchanted by the beauty of goddess Parvati, he looked at her with his evil intentions, but was immobilized by her wrath. Goddess Parvati then went to Lord Vishnu and narrated the whole tale. She requested Lord Vishnu to go to Jalandhar's wife in the guise of Jalandhar and act in the same way. With the help of his divine powers, Lord Vishnu created many inauspicious dreams while Vrinda was asleep. Vrinda became very restless and when the anxieties become unbearable she proceeded towards the forest. Vrinda saw a hermit in the forest who was preaching his disciples. The hermit was none other than Lord Vishnu. She went to that hermit and prayed to save her husband's life. Lord Vishnu disappeared from the there and reappeared in the guise of Jalandhar, but Vrinda was unable to recognize the real identity of her husband. She was very pleased after finding her husband. Both of them stayed in that very forest as husband and wife for a very long time.
One day, she came to know about the real identity of the person who was acting as her husband. Realizing that her chastity has been breached, she cursed Lord Vishnu that just as he had cheated her, in the same way somebody would abduct his wife and he too would wander in her search. After cursing Lord Vishnu, she left her life by entering into the fire. On the other side, after the departure of Parvati from Kailash Mountain and after the illusionary powers created by Jalandhar had ended all the apsaras and gandharvas vanished. Shiva realized that whatever he was watching was nothing more than illusion. Lord Shiva resumed his battle. The demons Shumbh and Nishumbh came forward to fight with him, but ultimately they had to flee from the battlefield. Then Jalandhar arrived to fight with Lord Shiva. A fierce battle commenced between them. Lord Shiva severed the head of Jalandhar by his 'Chakra, which had been created from his toe. After his death, Jalandhar's soul united with Lord Shiva.
Then dieties came to Lord Shiva and praised him. Lord Vishnu was very much saddened by the death of Vrinda. He took the ashes from the pyre and after applying them on his body started wondering here and there. The deities became very worried to see the condition of Lord Vishnu. They went to Lord Shiva and requested him to eliminate the false attachment with which Sri Vishnu was suffering. Lord Shiva sent the deities to Goddess Parvati, saying that she would help in this regard. The deities went to Goddess Parvati and prayed to her. She became very pleased and with the assistance of Goddess Lakshmi and Saraswati, gave some seeds to them. The deities sprayed those seeds on the pyre, on which Vrinda had given up her life. Three holy plants manifested from that pyre-Amla, Tulsi and Malti. Later on Tulsi and Malti attained to the Vishnuloka by the virtue of their penance.