Spain in the 17th century all contributed to the decline of the Habsburg rule of Spain. The end of the 17th century also brought the end of Habsburg rule. The 18th century began with the War of the Spanish Succession, which concluded in the establishment of the Bourbon dynasty in Spain. In 1469, Ferdinand II of Aragon and Isabella I of Castile united the Crowns of Aragon and Castile into one, creating the early modern Spanish state. Although this ensured future Spanish rulers would rule over both Aragon and Castile, both regions had their own administration and legal systems. In addition, Aragon itself was divided
House of Bourbon a "commoner" (referring back to the Medieval origins of the Bourbon Dynasty's name and referring to Hugh Capet, founder of the Capetian Dynasty). Members of the House of Bourbon-Condé and its cadet branches, which never ascended to the throne, used the surname "de Bourbon" until their extinction in 1830. The daughters of Gaston, Duke of Orleans, were the first members of the House of Bourbon since the accession of Henry IV to take their surname from the appanage of their father (d'Orleans). Gaston died without a male heir; his titles reverted to the crown. It was given to his nephew,