In 1626, Shahaji Raje Bhosale appointed Rango Bapuji Dhadphale as the administrator of Pune. He was one of the first major developers of the town, overseeing construction of some markets and residential areas like the Kasba Peth, Somwar Peth,
Raviwar Peth and Shaniwar Peth. After the destruction of the town in raids by the Adil Shahi dynasty in 1630 and again from 1636 to 1647, Dadoji Kondadev, a military and administrative officer of Shahaji, oversaw redevelopment and construction of the area. He stabilised the revenue system of Pune and the neighbourhoods of Maval to the west of town. In addition, he developed effective methods to control disputes and enforce law and order. Construction began on the Lal
Mahal palace, as Shahaji's son Shivaji was to move there with his mother Jijabai. The Lal Mahal was completed in 1640.[6] Jijabai is said to have commissioned the building of the Kasba Ganapati temple. The Ganesh idol consecrated at this temple is regarded as the presiding deity (gramadevata) of the city.[8]
Shivaji was crowned Chhatrapati in 1674, thus founding the Maratha Empire. He oversaw further development in Pune, including the construction of the Guruwar Peth, Somwar Peth, Ganesh Peth and Ghorpade Peth. Shivaji encouraged development of dams in Parvati and Kondhwa regions of Pune for agriculture purposes. Pune and surrounding villages later provided manpower for Shivaji's efforts to build an army during the period from 1645 to 1680. Between 1660 and 1670 the town was captured by Mughal General Shahista Khan, but was recaptured by the Marathas in 1670 after the battle of Sinhagad.
During the 27-year long conflict between the Marathas and the Mughals, the town was occupied by Aurangzeb from 1703 to 1705; during this time the name of the town was changed to "Muhiyabad".[citation needed] Two years later, the Marathas recaptured Sinhagad fort and later Pune city from the Mughals as had been done in 1670.