Charles II of Spain (Spanish: Carlos II; 6 November 1661 – 1 November 1700) was the last Habsburg ruler of Spain. His realm included Southern Netherlands, Italian territories, several cities in north Africa and Spain's overseas empire, stretching from the Americas to the Spanish East Indies. Known as "the Bewitched" (Spanish: el Hechizado), he is noted for his extensive physical, intellectual, and emotional disabilities and his consequent ineffectual rule.
He died in 1700, childless and heirless, with all potential Habsburg successors having predeceased him. In his will, Charles named as his successor the almost 17-year-old Philip, Duke of Anjou, grandson of Charles' half-sister Maria Theresa of Spain, the first wife of Louis XIV (and thus grandson of the reigning French king Louis XIV). Because the other European powers viewed the prospective dynastic relationship between France and Spain as disturbing the balance of power in Europe, the War of the Spanish Succession ensued shortly after his death.
(Excerpt from Wikipedia)