Mahakaleshwar Temple is one of the twelve Jyotirlingas in India. This is the main temple of Lord Mahakaleshwar, located in Ujjain city of Madhya Pradesh state. The beautiful description of this temple is found in the works of great poets like Puranas, Mahabharata, and Kalidas. Being self-proclaimed, grand, and south-facing, Mahakaleshwar Mahadev has great virtuous importance. The mere sight of it leads to salvation. There was a delightful city by the name of Avanti, which was very dear to Lord Shiva. A knowledgeable Brahmin lived in this city, who was a very intelligent and ritualistic Brahmin. Also, Brahmins were great devotees of Shiva.
He used to worship it every day by making a Parthiv Shivling. The name of the Brahmin was Veda Priya, who was always engaged in acquiring the knowledge of the Vedas. The brahmin had received the full fruit of his actions. A demon named Dushan lived on the Ratnamal mountain. This demon had got a boon from Brahma Ji. Due to this boon, he started attacking religious people. He made up the idea of attacking the Brahmins of Ujjain. For this reason, he started harassing the Brahmins of Avanti Nagar with his antics. He started forbidding Brahmins from performing rituals. Asked to stop the work of Dharma-karma, but the Brahmins did not pay heed to him.
However, he was harassed by the demons every day. The brahmins, fed up with this, started praying to Shiva Shankar for their protection. Lord Shiva at the Vinaya of the brahmins warned them before stopping the tyranny of the demon. One day the demons attacked. Lord Shiva tore the earth and appeared in the form of Mahakal. Angry Shiva consumed the evil demon with one of his hooters. Overwhelmed by the demand of the devotees to stay there, the Lord sat there. For this reason, this place was named Mahakaleshwar, which you know as Mahakaleshwar Jyotirlinga.