By end of 1378 the Muslim rulers were defeated by Vijayanagara army and later established their rule. In 1559 Madurai Nayaks, till then part of Vijayanagara empire became powerful and with Dindigul became a strategic gateway to their kingdom from North . After the death of King Viswanatha Nayak in 1563, Muthukrisna Nayakka became the king of kingdom in 1602 A.D who built the strong hill fort in 1605 A.D. He also built a fort at the bottom of the hill. Muthuveerappa Nayak and Thirumalai Nayak followed Muthukrishna Nayak. Dindigul came to prominence once again during Nayaks rule of Madurai under Thirumalai Nayak. After his immediate unsuccessful successors, Rani Mangammal became the ruler of the region who ruled efficiently.. In 1742, the Mysore army under the leadership of Venkata Raya conquered Dindigul. He governed Dindigul as a representative of Maharaja of Mysore. There were Eighteen Palayams (a small region consists of few villages) during his reign and all these palayams were under Dindigul Semai with Dindiguls capital. These palayams wanted to be independent and refused to pay taxes to venkatarayer. In 1748, Venkatappa was made governor of the region in place of Venkatarayer, who also failed. In 1755, Mysore Maharaja sent Haider Ali to Dindigul to handle the situation. Later Haider Ali became the de facto ruler of Mysore and in 1777, he appointed Purshana Mirsaheb as governor of Dindigul. He strengthened the fort. His wife Ameer-um-Nisha-Begam died during her delivery and her tomb is now called Begambur. In 1783 British army, led by captain long invaded Dindigul. In 1784, after an agreement between the Mysore province and British army, Dindigul was restored by Mysore province. In 1788, Tipu Sultan, the Son of Haider Ali, was crowned as King of Dindigul. In 1790, James Stewart of the British army gained control over Dindigul by invading it in the second war of Mysore. In a pact made in 1792, Tipu ceded Dindigul along with the fort to the English.