The Indian Puranas like Shiva Purana, Mudgala Purana, Linga Purana, Brahmavaivarta Purana and Ganesha Purana, mention the legend related to the Vighnaraja form of Ganesha. Goddess Parvati(Uma) was the daughter of Himavat, the god of snow. She was married with Lord Shiva. Once when She was with her family and friends, Parvati started laughing in a jovial manner. Suddenly a young handsome man manifested from Her laughter and bowed to the Goddess. Parvati was surprised at this incident and asked him about his identity and his purpose. The young man replied that he was born from the divine laughter of the Goddess and his objective was to serve his mother. Parvati named him Mama and told him to pray to Lord Ganesha for the fulfillment of his desires.
Mama went to the forests and engaged himself in deep meditation and worship of Ganesha. Later he met with an asura named Sambara. The demon introduced Mama to the demonic cult and taught him the worship rituals of the asuras. Hence the divine Mama turned into the demonic Mamasura. He married Mohini and became the King of the three Lokas or worlds. He exiled several Devas from heaven and created obstacles for other gods and sages. Then all the gods prayed to Lord Ganesha for help. Thus, Ganesha took the form of Lord Vighnaraja and defeated the demon Mamasura. He then re-established peace and righteousness in the three Lokas. Hence, the Hindu God is regarded as the remover of all the obstacles.
Devotees of Ganesha worship the Vighnaraja form as the Lord removes all fears from the minds of the worshippers. He destroys all evils and manifests before His devotees in the form of blessings.