THE MEDIEVAL ORIGINS OF ANDORRA During the Middle Ages, the valleys of Andorra formed part of the political and religious territories associated with the County of Urgell. In 1133, Count Ermengol VI transferred his rights over Andorra to the Bishop of Urgell. The bishops subsequently shared aspects of their feudal authority with the noble House of Caboet. Through dynastic marriages and inheritance, these secular rights eventually passed to the Counts of Foix. THE PAREATGES AND THE FOUNDATION OF THE CO-PRINCIPALITY (1278–1288) Conflicts between the Bishop of Urgell and the Count of Foix resulted in a historic agreement known as the First Pareatge. On September 8, 1278, Bishop Pere d'Urtx and Count Roger-Bernard III of Foix agreed to share authority over Andorra. A second Pareatge in 1288 clarified their respective rights and obligations. These agreements established the foundations of Andorra's unique system of joint sovereignty. THE HOUSE OF FOIX AND THE FRENCH CROWN (13TH–17TH CENTURIES) The secular rights of the Counts of Foix passed through several noble and royal families. Through dynastic inheritance, these rights eventually became associated with the Kingdom of Navarre. In 1589, Henry III of Navarre became King Henry IV of France. In 1607, he formally united the secular co-princely rights with the French Crown. The French monarch and the Bishop of Urgell consequently became the two co-princes of Andorra. THE FRENCH REVOLUTION AND THE RESTORATION OF THE CO-PRINCIPALITY (1793–1806) During the French Revolution, the French authorities renounced their traditional feudal relationship with Andorra. This temporarily interrupted the system of shared sovereignty. In 1806, Napoleon I restored the French co-princely rights at the request of the Andorran authorities. The arrangement survived subsequent changes in French government, including the transition from monarchy to republic.