In 1707 Aurangzeb died. After his death, 13 rulers of the Mughal dynasty ruled India. They were known as Later Mughals. During their rule, the dynasty’s power began to decline. As the Central administration became weak, regional rulers started becoming more and more autonomous. The Later Mughals failed to prevent foreign attacks. Although the Mughal Empire was breaking up, the Mughal rulers tried to maintain their status and glory. They continued symbolically. In 1857, the British dethroned the last Mughal ruler Bahadur Shah Safar II. With this, the Mughal rule ended. The Mughal capitals were Agra (Babur), Fatehpur Sikri, Lahore (Akbar), Shajahanabad (Shah Jahari).