Catalonia is an autonomous community of Spain located on the northeastern extremity of the Iberian Peninsula. It is designated as a nationality by its Statute of Autonomy. Catalonia consists of four provinces: Barcelona, Girona, Lleida, and Tarragona. The capital and largest city is Barcelona, the second-most populated municipality in Spain and the core of the seventh most populous urban area in the European Union. Catalonia comprises most of the territory of the former Principality of Catalonia (with the remainder Roussillon now part of France's Pyrénées-Orientales). It is bordered by France and Andorra to the north, the Mediterranean Sea to the east, and the Spanish autonomous communities of Aragon to the west and Valencia to the south. The official languages are Catalan, Spanish, and the Aranese dialect of Occitan.
Founded as a Roman city, in the Middle Ages Barcelona became the capital of the County of Barcelona. After merging with the Kingdom of Aragon, Barcelona continued to be an important city in the Crown of Aragon as an economic and administrative centre of this Crown and the capital of the Principality of Catalonia. Barcelona has a rich cultural heritage and is today an important cultural centre and a major tourist destination. Particularly renowned are the architectural works of Antoni Gaudí and Lluís Domènech i Montaner, which have been designated UNESCO World Heritage Sites. The headquarters of the Union for the Mediterranean is located in Barcelona. The city is known for hosting the 1992 Summer Olympics as well as world-class conferences and expositions and also many international sport tournaments.
Barcelona is one of the world's leading tourist, economic, trade fair and cultural centres, and its influence in commerce, education, entertainment, media, fashion, science, and the arts all contribute to its status as one of the world's major global cities. In 2008 it was the fourth most economically powerful city by GDP in the European Union and 35th in the world with GDP amounting to €177 billion. In 2012 Barcelona had a GDP of $170 billion; and it was leading Spain in employment rate in that moment.
In about 15 BC, the Romans redrew the town as a castrum (Roman military camp) centred on the "Mons Taber", a little hill near the contemporary city hall (Plaça de Sant Jaume). Under the Romans, it was a colony with the surname of Faventia, or, in full, Colonia Faventia Julia Augusta Pia Barcino or Colonia Julia Augusta Faventia Paterna Barcino. Pomponius Mela mentions it among the small towns of the district, probably as it was eclipsed by its neighbour Tarraco (modern Tarragona), but it may be gathered from later writers that it gradually grew in wealth and consequence, favoured as it was with a beautiful situation and an excellent harbour. The city minted its own coins; some from the era of Galba survive.
Important Roman vestiges are displayed in Plaça del Rei underground, as a part of the Barcelona City History Museum MUHBA; the typically Roman grid plan is still visible today in the layout of the historical centre, the Barri Gòtic (Gothic Quarter). Some remaining fragments of the Roman walls have been incorporated into the cathedral. The cathedral, also known as the Basilica La Seu, is said to have been founded in 343.
The city was conquered by the Visigoths in the early 5th century, becoming for a few years the capital of all Hispania. After being conquered by the Arabs in the early 8th century, it was conquered in 801 by Charlemagne's son Louis, who made Barcelona the seat of the Carolingian "Hispanic March" (Marca Hispanica), a buffer zone ruled by the Count of Barcelona.
The Counts of Barcelona became increasingly independent and expanded their territory to include all of Catalonia, although on 6 July 985, Barcelona was sacked by the army of Almanzor. The sack was so traumatic that most of Barcelona's population was either killed or enslaved. In 1137, Aragon and the County of Barcelona merged in dynastic union by the marriage of Ramon Berenguer IV and Petronilla of Aragon, their titles finally borne by only one person when their son Alfonso II of Aragon ascended to the throne in 1162. His territories were later to be known as the Crown of Aragon, which conquered many overseas possessions and ruled the western Mediterranean Sea with outlying territories in Naples and Sicily and as far as Athens in the 13th century. The forging of a dynastic link between the Crowns of Aragon and Castile marked the beginning of Barcelona's decline. The Bank of Barcelona (Taula de canvi), probably the oldest public bank in Europe, was established by the city magistrates in 1401. It originated from necessities of the state, as did the Bank of Venice (1402) and the Bank of Genoa (1407).
The marriage of Ferdinand II of Aragon and Isabella I of Castile in 1469 united the two royal lines. Madrid became the centre of political power whilst the colonisation of the Americas reduced the financial importance (at least in relative terms) of Mediterranean trade. Barcelona was a centre of Catalan separatism, including the Catalan Revolt (1640−52) against Philip IV of Spain. The great plague of 1650−1654 halved the city's population.
In the 18th century, a fortress was built at Montjuîc that overlooked the harbour. In 1794, this fortress was used by the French astronomer Pierre François André Méchain for observations relating to a survey stretching to Dunkirk that provided the official basis of the measurement of a metre. The definitive metre bar, manufactured from platinum, was presented to the French legislative assembly on 22 June 1799. Much of Barcelona was negatively affected by the Napoleonic wars, but the start of industrialisation saw the fortunes of the province improve.
During the Spanish Civil War, the city, and Catalonia in general, were resolutely Republican. Many enterprises and public services were "collectivized" by the CNT and UGT unions. As the power of the Republican government and the Generalitat diminished, much of the city was under the effective control of anarchist groups. The anarchists lost control of the city to their own allies, the Communists and official government troops, after the street fighting of the Barcelona May Days. The fall of the city on 26 January 1939, caused a mass exodus of civilians who fled to the French border. The resistance of Barcelona to Franco's coup d'état was to have lasting effects after the defeat of the Republican government. The autonomous institutions of Catalonia were abolished, and the use of the Catalan language in public life was suppressed. Barcelona remained the second largest city in Spain, at the heart of a region which was relatively industrialised and prosperous, despite the devastation of the civil war. The result was a large-scale immigration from poorer regions of Spain (particularly Andalusia, Murcia and Galicia), which in turn led to rapid urbanisation.