The Kingdom of Galicia was a political entity located in southwestern Europe, which, at its territorial zenith, occupied the entire northwest of the Iberian Peninsula. In the early 10th century, the Kingdom of Galicia was formed following the division of the Kingdom of Asturias after the death of Alfonso III in 910. His sons split the kingdom, with Ordoño II inheriting Galicia. While Galicia became a distinct political entity, it remained closely tied to the Leonese and Asturian realms through dynastic connections. Later, Ordoño II would integrate Galicia into the Kingdom of León when he inherited the latter. Though the Kingdom of Galicia had moments of semi-independence, it was typically seen as part of the Kingdom of León. Compostela became the capital of Galicia in the 11th century, while the independence of Portugal (1128) determined its southern boundary. The accession of Castilian King Ferdinand III to the Leonese kingdom in 1230 brought Galicia under the control of the Crown of Castile.
Galicia resisted central control and supported a series of alternative claimants, including John of León, Galicia and Seville (1296), Ferdinand I of Portugal (1369) and John of Gaunt (1386) and was not brought firmly into submission until the Catholic Monarchs imposed the Santa Hermandad in Galicia. The Kingdom of Galicia was then administered within the Crown of Castile (1490–1715) and later the Crown of Spain (1715–1833) by an Audiencia Real directed by a Governor which also held the office of Captain General and President. The representative assembly of the Kingdom was then the Junta or Cortes of the Kingdom of Galicia, which briefly declared itself sovereign when Galicia remained free of Napoleonic occupation (except during January–July 1809). The kingdom and its Junta were dissolved by Maria Cristina of Bourbon-Two Sicilies, Regent of Spain, in 1834.