Portugal, officially the Portuguese Republic (República Portuguesa ), is a country located mostly on the Iberian Peninsula in southwestern Europe. It is the westernmost sovereign state of mainland Europe. It is bordered to the west and south by the Atlantic Ocean and to the north and east by Spain. Its territory also includes the Atlantic archipelagos of the Azores and Madeira, both autonomous regions with their own regional governments.
Portugal is the oldest state on the Iberian Peninsula and one of the oldest in Europe, its territory having been continuously settled, invaded and fought over since prehistoric times. The pre-Celtic people, Celts, Carthaginians and Romans were followed by the invasions of the Visigoths and Suebi Germanic peoples. Portugal as a country was established during the Christian Reconquista against the Moors who had invaded the Iberian Peninsula in 711 AD. Founded in 868, the County of Portugal gained independence after the Battle of São Mamede in 1128. The Kingdom of Portugal was proclaimed following the Battle of Ourique in 1139 and was recognised by the neighbouring kingdoms by the Treaty of Zamora in 1143.
In the 15th and 16th centuries, Portugal established the first global empire, becoming one of the world's major economic, political and military powers. During this period, today referred to as the Age of Discovery, Portuguese explorers pioneered maritime exploration, notably under royal patronage of Prince Henry the Navigator and King John II, with such notable voyages as Bartolomeu Dias' sailing beyond the Cape of Good Hope (Cabo da Boa Esperança) (1488), Vasco da Gama's discovery of the sea route to India (1497–98) and the European discovery of Brazil (1500). During this time Portugal monopolized the spice trade, and the empire expanded with military campaigns in Asia. However, events such as the destruction of Lisbon in a 1755 earthquake, the Industrial Revolution, the Seven Years' War, the country's occupation during the Napoleonic Wars, and the independence of Brazil (1822), erased to an extent Portugal's prior opulence.
After the 1910 revolution deposed the monarchy, the democratic but unstable Portuguese First Republic was established, later being superseded by the Estado Novo right-wing authoritarian regime. Democracy was restored after the Carnation Revolution in 1974, ending the Portuguese Colonial War. Shortly after, independence was granted to almost all its overseas territories. The handover of Macau to China in 1999 marked the end of what can be considered the longest-lived colonial empire.
Portugal has left a profound cultural and architectural influence across the globe, a legacy of 300 million Portuguese speakers, and many Portuguese-based creoles. A member of the United Nations and the European Union, Portugal was also one of the founding members of NATO, the eurozone, the OECD, and the Community of Portuguese Language Countries. It is a developed country with a high-income advanced economy and high living standards. It is the 4th most peaceful country in the world, and its state is the 15th most stable one, maintained under a unitary semi-presidential republican form of government. Additionally, the country ranks highly in terms of democracy (10th), social progress (20th), prosperity (25th), press freedom (14th), moral freedom (3rd), LGBT rights (7th in Europe), ease of doing business (29th) and road network (2nd).
The word Portugal derives from the Roman-Celtic place name Portus Cale. Portus, the Latin word for port or harbour, Cala or Cailleach was the name of a Celtic goddess – in Scotland she is known as Beira – and also the name of an early settlement located at the mouth of the Douro River (present-day Vila Nova de Gaia) which flows into the Atlantic Ocean in the north of what is now Portugal. At the time the land of a specific people was frequently named after its deity. Those names are the origins of the -gal in Portugal and Galicia. Incidentally, the meaning of Cale or Calle is also a derivation of the Celtic word for port which would confirm very old links to pre-Roman, Celtic languages which compare to today's Irish caladh or Scottish cala, both meaning port. Some French scholars believe it may have come from 'Portus Gallus', the port of the Gauls or Celts.
Around 200 BC, the Romans took the Iberian Peninsula from the Carthaginians during the Second Punic War, and in the process conquered Cale and renamed it Portus Cale (Port of Cale) incorporating it to the province of Gaellicia with capital in Bracara Augusta (modern day Braga, Portugal). During the Middle Ages, the region around Portus Cale became known by the Suebi and Visigoths as Portucale. The name Portucale evolved into Portugale during the 7th and 8th centuries, and by the 9th century, that term was used extensively to refer to the region between the rivers Douro and Minho. By the 11th and 12th centuries, Portugale, Portugallia or Portvgalliae was already referred to as Portugal.