The followers of the Vedas embraced the worship of Shiva around 600 B.C. They recognized both the benevolent aspect of Shiva and the fierce aspect - Rudra - as two sides of the same coin. The influence of Shiva spread beyond Aryavarta. In 1270, Vishaldev Vaghela of Gujarat sent his knowledgeable Minister Pandit Nanak to engage in a religious debate with Jain Acharya Hemchandrasuri.

Legend has it that Arjun, after violating a code of conduct established between brothers by marrying Draupadi, exiled himself to the forest for 12 years. During his exile, he resided in the land of the Nagas, where he fathered a son with Ullupi. He then moved on to stay with Chitrangada, the daughter of King Chitravat. Arjun later married Shri Krishna's sister, Subhadra. Following the Mahabharata war, the Pandavas conducted the Ashvamedha Yagna on the advice of Ved Vyas.

During the Yagna, Shri Krishna, who attended the event, miraculously revived the deceased son of Uttara, bringing joy to all. However, this joy was short-lived when Babruvahan, Arjun's son who was living among the Nagas, unknowingly defeated and killed his father. Ullupi then instructed Babruvahan to pray before the Shivling, which was worshipped by his grandfather, Hatak, the king of the Nagas. The Sanjivani granted by the Hatak Shivling revived Arjun. The family then brought the Hatak Shivling from the Nag areas of Assam and Madhya Pradesh to Vadnagar, where it was worshipped as Hatkeshwar by the Nagars.

In the Skand Purana, it is mentioned that Shiv created the Nagars to celebrate his marriage to Uma and allocated land for their settlement in Vadnagar.