The Peace of Basel, signed on July 22, 1795 between Revolutionary France and the Kingdom of Spain, ended the War of the Pyrenees (1793-1795). During that war, French troops had occupied much of Hegoalde and there was even support among certain groups in Gipuzkoa for the province being fully annexed by France.
In the negotiations leading up to the signing of the Peace of Basel in 1795 the French enjoyed the upper hand and seriously considered holding on to Gipuzkoa, but ultimately the wider global context–and especially the offer of economically appealing terrain in the Caribbean–meant that Gipuzkoa would be returned to the Kingdom of Spain.
A century earlier, by the Treaty of Ryswick (1697), the western part of the Spanish-controlled island of Hispaniola had been ceded to the French, who were eager to expand their own power and influence in the Caribbean. Indeed, this was a feature of both pre- and post-revolutionary France. During the negotiations over the 1795 peace treaty, Spain was desperate to recover its lost “national” territory (and punish those people in in Gipuzkoa who had sided with the French), so much so that it offered France complete control of Hispaniola in exchange for the return of the occupied Basque lands (and other territory in Catalonia).
Additionally, there was an annex to the treaty by which any Basques in Hegoalde (and specifically Gipuzkoa) who had shown sympathies for the occupying French were given guarantees of receiving no reprisals from Spanish authorities. Yet the immediate effects of the treaty for Gipuzkoa, and Donostia-San Sebastián in particular, were severe: many of the political and military leaders who had attempted to broker a deal with the French invaders were arrested, along with ordinary citizens, and sentenced to jail sentences, exile, and even in one case–that of José Javier Urbiztondo–death by hanging.
Across the Atlantic, France found it increasingly difficult to hold the island and its forces were withdrawn in 1803. Following a successful slave revolt, the independent Republic of Haiti (in the western part of the island marking the original territory of French settlement) was proclaimed in 1804. In the eastern part of the island, meanwhile, a more tortuous path eventually resulted in a lasting independence (following previous attempts in 1821 and 1844) for the Dominican Republic in 1865.