Spain under Joseph Bonaparte

Kingdom of (the) Spain(s) and (the) Indies
Reino de las Españas y las Indias (Spanish)
Royaume d'Espagne et des Indies (French)
1808–1813
Motto: Plus Ultra (Latin)
"Further Beyond"
Anthem: Marcha Real (Spanish)
"Royal March"
  Spanish territory occupied at some point during the war by King Joseph Bonaparte.
  Military governments dependent on Paris (since 1810): Biscay, Navarre and Aragon
  Military government of Catalonia, dependent on Paris (since 1810) / Territory annexed to the French Empire (from 1812 until the Treaty of Valençay in 1813).
  Territory never occupied by Joseph Bonaparte's government, besides Spanish America, the Philippines, Spanish Guinea: Canary Islands, Cadiz, Ceuta, Melilla, Cartagena, Alicante and Balearic Islands.
StatusClient state of the French Empire
CapitalMadrid
Official languagesSpanish
French (dynastic)
Common languagesCatalan
Basque
Galician
Religion
Catholicism (State Religion)
DemonymsSpaniard, Spanish
GovernmentUnitary semi-constitutional monarchy
King 
• 1808–1813
Joseph I
Regent 
• 1808
Joachim Murat
First Secretary of State 
• 1808–1813
Mariano Luis de Urquijo
• 1813
Juan O'Donoju O'Ryan
• 1813
Fernando de Laserna
LegislatureCortes Generales
Historical eraNapoleonic Wars
6 May 1808
8 July 1808
21 June 1813
11 December 1813
CurrencySpanish real
Preceded by
Succeeded by
Kingdom of Spain
Spain
Today part ofSpain

Bonapartist Spain was a Napoleonic client state established in 1808 after Napoleon, who had stationed his Imperial Army in Spain under the pretense of a joint Franco–Spanish invasion of Portugal, forced the ruling Spanish Bourbons to abdicate, and installed his brother, Joseph Bonaparte on the Spanish throne, which ignited a people's revolt by Spanish citizens and led to the Peninsular War, where France was defeated and forced to retreat from Spain.

The kingdom was officially known as Kingdom of (the) Spain(s) and (the) Indies, with "the Indies" referring to the East and West Indies as well as Spain's colonial possessions more broadly. It never managed to exert control over these territories however, not only did the French invasion weaken Spain's grasp on its overseas empire, kickstarting the Spanish American wars of independence, but even on the Spanish mainland, the House of Bonaparte's grip was tenuous. Large parts of the country came under the control of juntas, which remained loyal to Ferdinand VII and the old Bourbon kingdom, allying with the Coalition forces of Britain and Portugal to undermine the French occupation.

Guerrilla warfare bogged down French troops for years in Iberia, which hindered the French military and Napoleon referring to Spain as the Spanish Ulcer. A series of decisive Coalition victories from 1812 to 1813 at Salamanca and Vitoria meant the defeat of the Bonapartist régime and the expulsion of Napoleon I's troops. In the Treaty of Valençay Napoleon recognized Ferdinand VII as the legitimate King of Spain, though the Bourbon and Anglo-Portuguese forces continued to pursue the retreating French Imperial Army as part of the Sixth Coalition in an invasion of France.