To be precise, the military station of Fatehgarh dates from 1777, although the town did not pass into the possession of the British until 1802. In this period Farrukhabad had fallen under the power of the Wazirs of Awadh and Fatehgarh formed an important outpost against the Maratha war bands. The British brigade lent to the Nawab Wazir was stationed in Fatehgarh in 1777. At the cession of 1802, Fatehgarh became the headquarters of a Governor-General's Agent and of the Board of Commissioners for the Ceded Provinces. Yashwantrao Holkar attacked the fort of Fatehgarh in 1804 but in the famous Battle of Farrukhabad, part of the ongoing Second Anglo-Maratha War, Holkar was defeated and put to flight by the timely arrival of Lord Gerard Lake. From this time, nothing eventful occurred in the history of Fatehgarh until the outbreak of the Rebellion of 1857.