The Free City of Besançon was a self-governing free city surrounded by Franche-Comté. After losing its status as a free imperial city within the Holy Roman Empire in 1654, the City of Besançon refused to recognise the sovereignty of a new protector, whether the king of France or Spain, until Louis XIV dissolved the municipal government in 1676. The government comprised only a tiny area around the City of Besançon in the Franche-Comté, which meant that it had limited independence although it had considerable internal autonomy and still tried to claim neutrality. History Within the Holy Roman Empire Besançon became part of the Holy Roman Empire in 1034 as the Archbishopric of Besançon, and in 1184 it gained autonomy as a free imperial city under Frederick I, Holy Roman Emperor. The town slowly sought the protection of a number of outside protectors, or captains, such as Philip the Good, Duke of Burgundy. After the marriage of Mary of Burgundy to Maximilian I, Holy Roman Emperor in 1477, the city treated the Habsburgs as its protectors. When Franche-Comté passed to Philip II of Spain in 1555, Besançon remained a free imperial city. Loss of Imperial status The city lost its status as a free imperial city in 1651 as a reparation for other losses that the Spanish had suffered in the Thirty Years' War. After some resistance, this was finally confirmed by Besançon in 1654, although the city kept a high degree of internal autonomy. Disputes with France In 1667 Louis XIV claimed Franche-Comté as a consequence of his marriage to Marie-Thérèse of Spain. As part of the War of Devolution, French troops arrived in the area in 1688. The town authorities tried to argue that it was neutral in any hostilities as it was an Imperial City, something that the French commander, the Prince de Conde, rejected as archaic. The French agreed to very generous surrender terms with the town authorities, which included transferring the university from the then still recalcitrant Dole. There were also rumours that the regional Parlement may be transferred from Dole. The City also laid down that it would be left the relic of a fragment of the holy winding sheet, and that Protestants should not have liberty of conscience in the same way as they then had in the rest of France. While the city was in French hands, the famed military engineer Sébastien Le