1713: Treaties of Utrecht confirm a Bourbon king in Spain
By 1711 the end of the Spanish male line and the death of Emperor Joseph I had left his brother Charles as the last male Habsburg.
The Treaties of Utrecht in 1713 recognised the Bourbon accession to Spain and Spanish America, Britannica says. The Spanish crown was lost to the family.