Castaños is remembered for his victory over the French under Dupont, whom he surrounded and compelled to surrender at the decisive Battle of Bailen in 1808, where the Napoleonic army was defeated in the open field for the first time and which led to King Joseph having to abandon Madrid at the end of that same month.[2] Just months later he led his army to a decisive defeat at the Battle of Tudela. After this he served under Wellington in several engagements, and was commander of the Spanish army, if required, to invade France in 1815.
His victory over DupontFrench troops at Bailen (19 July 1808), in the early stages of the war, was the first time the Napoleonic army had ever been defeated in the open field and led to King Joseph having to abandon Madrid at the end of that month.[2]
On returning to Seville, Castaños was appointed captain general and preparations were made for the Spanish army to enter Madrid mid-August.[2]
Having been given command of the Army of the Centre, which he joined at Tudela in mid-October, his troops were heavily defeated there at the following month the Battle of Tudela (23 November 1808).[2] Castaños withdrew towards Somosierra, north of Madrid, to cut off Napoleon's advance on Madrid, but he was relieved of his command and made to go to Seville, where the Supreme Junta was now based, and from there, on to Algeciras to await the court martial for his defeat.[2]
Post-war career
Following Napoleon's flight from Elba, and the start of the Hundred Days, Castaños was given command of the Army of Observation of the Right and crossed into Roussillon. With Napoleon defeated at Waterloo, Castaños was appointed captain general of Catalonia.[2]
In 1837 he was appointed senator for the province of Barcelona, seat he held until 1845, apart from the period 1841–1844. In 1845 he was appointed senator for life.[4]