The First invasion of Portugal in 1807 resulted in the French occupation of that nation. This episode came to an end on 21 August 1808 when the invaders were defeated by Sir Arthur Wellesley's British army at the Battle of Vimeiro. Anxious to quickly liberate Portugal, the victorious British generals concluded the Convention of Cintra in which the French occupying army was transported back to France by British ships.