Ujjain Mahakaleshwar Shivaling is considered self-reliant Shivling, it is receiving the streams of power from within itself while others have been formally installed with Shivling mantras.
It is difficult to tell when the Mahalkal Temple came into existence, but the Mahakal temple is mentioned in much ancient Indian poetry, which describes the architecture and grandeur of the temple. According to the Puranas, it was founded by Prajapati Brahma. The temple is mentioned in the 6th century, in which the Prince Kumarasen was appointed by Chanda Pragya to see the temple arrangement. With this, 5 coins of the third and fourth century B.C., on whom Mahakaleshwar is inscribed with the shape of Lord Shiva, certifies that the temple was present that time.
Some old documents also confirm that even the Sultans of Malwa and Mughal emperors have donated amounts to the priests of Mahakaleshwar temple for maintenance of temple and conduct prayers to ask safety of their region. Thus it’s evident that even Islamic Rulers acknowledged the power of Mahakaleshwar temple and extended financial support to the temple.
Peshwa Bajirao-1 had entrusted the administration of Ujjain to his loyal Ranoji Shinde. Ranoji’s diwan named Sukhnath Ramchandra Baba Sheenavi was very rich but he had no heir or child to carry his family name forward. Panditas and scholars suggested Ramchandra Baba Sheenavi use wealth in the work of religion. And so as per advised he started the reconstruction of the Ujjain Mahakaleshwar temple that was done in the fourth and fifth decade of the eighteenth century.