According to a legend, Gwalior was once ruled by a king named Suraj Sen. A time came when he was suffering from leprosy which was incurable. A sage named Gwalipa gave him water from a sacred pond which cured his disease. In order to honour the sage, the king constructed the fort.
The king got the title of Pal from the sage and a boon that the fort will be in his possession and the generations to come. History says that 83 generations of the king successfully ruled from this fort but the king of 84th generation named Tej Karan could not protect the fort and lost it.
There are inscriptions in the fort which date back to sixth century and indicate that the fort may have been constructed in those times. Mihirakula, a Huna emperor, built a sun temple here.
In 9th century, Teli ka Mandir was built by the rulers of Gurjara-Pratihara dynasty. In 10th century, Kachchhapghatas controlled the fort. These people worked under the leadership of Chandelas.
In 11th century, Muslim dynasties began attacking the fort. Mahmud of Ghazni attacked the fort in 1022AD. Qutubuddin Aibak captured the fort in 1196AD and annexed it to Delhi Sultanate. Though the sultanate lost the fort but was again captured by Iltumish 1232.
Tomar Rajputs captured the fort in 1398. Maan Singh was one of the famous Tomar Rajput who built many monuments inside the fort. Sikandar Lodi attacked the fort in 1505 but could not capture it. His son Ibrahim Lodi attacked the fort in 1516. In this attack, Maan Singh was killed and after a long siege Rajputs surrendered.
Mughals captured the fort but lost it to Suris. In 1542, Akbar again captured the fort and made it a prison. He executed his cousin Kamran in the fort. Aurungzeb also killed his brother Murad and his nephews here. After Aurungzeb, Ranas of Gohad captured the fort. They lost to the Marathas and Marathas lost it to British. The British gave the fort to the Ranas of Gohad in 1780.
Marathas again captured the fort in 1784. This time due to the hostility of Ranas of Gohad, British cannot capture the fort. British defeated Daulat Rao Scindia and recaptured the fort later. In 1886, India was in full control of the British so they gave the fort to the Scindias who ruled the fort till 1947.