Daoíz volunteered to help defend Ceuta against the Moors in 1790 and was given command of an artillery battery.
Spain signed the Second Treaty of San Ildefonso in 1796, allying itself with France against Great Britain and beginning the Anglo-Spanish War.