[citation needed] Administratively, the municipality is divided into 4 civil parishes (freguesias):[6] Commanding views across the Tagus basin and Serra de Estrela to the north, the fortified rock of Marvão has been a site of significant strategic importance since the earliest human settlements.
[citation needed] Marvão's natural assets have contributed to the 'uniqueness' of this remote village as perceived by visitors today: (i) as nigh-impregnable 'eagle's nest' fortress - perched high on a granite crag, and bordered on the south and west by the Sever river; (ii) as vital lookout-point towards the Alcántara Bridge (70 km (43 mi) away), a wide stretch of the Tagus basin and the Serra de Estrela; (iii) as a gateway to Portugal from Spain via the Porta da Espada ('Sword Gate') mountain pass of the Serra de São Mamede.
Cave art and engravings in the Tagus valley (40 km (25 mi) north of Marvão: 40,000 items) point to a developed culture based on prehistoric norms of agriculture, hunting and transhumance.
Decorative objects - rock crystal arrowheads, floral- and zig-zagged patterned stones (pedras de raio) and ceramics, deity sculptures - also suggest the development of local systems of craftsmanship, hierarchy, magic and celebration.
[13] Recent studies of idol plaques have speculated that they depict some kind of owl deity, with their engravings acting as a means to identify the individual buried by clan, marriage and lineage.
The site of modern-day Marvão would have stood on the northern periphery of the territory of the Celtici tribe, which stretched from the Tagus to Guadiana rivers, and beyond to the Algarve and today's Huelva province in Andalucia.
A series of bloody revolts and wars (195–135 BCE) pitted the Lusitanians and Vettones - most notably under the guerrilla fighter and hero Viriatus – against the expansionist Roman colonisers of Hispania Ulterior.
The Vettones culture was renowned for its cattle-rearing and Verraco (Portuguese: berrão) pig-like sculptures: porco preto rearing remains dominant in local agriculture and cuisine.
[20] Ammaia's location on the river Sever was a waypoint on west–east trading routes, linking towns such as Scallabis (Santarém), Eboracum (Évora), Olisipo (Lisbon) and Miróbriga (Santiago de Cacém) to the provincial capital Emerita Augusta (present-day Mérida) via Norba Caesarina (Cáceres).
[20] During the 5th-7th century, the invasion of Roman Iberia by a succession of tribes from Central Europe - the Vandals, Suevi, Alans and Visigoths - left an indelible mark on Marvão and Lusitania as a whole.
Five centuries of incumbent Hispano-Roman urban culture gave way to interaction with the nomadic, pastoralist lifestyles of tribes such as the Alans (dominant in much of former Lusitania after the Battle of Mérida).
[23] Following the chaotic decades of invasion, by the later 8th century CE Marvão would have formed part of the Western thughūr ('march' i.e. buffer area or boundary zone) ruled by a marcher lord, or ka'id from the old Lusitanian capital of Mérida.
The Lower March - the territorial division known as Xenxir - gained a reputation for the rebelliousness and reluctance of its inhabitants to comply with governance from Cordoba, with Mérida being a seething hive of discontent, revolution and tax-refuseniks.
[23] Historical sources do not explain the precise role of Marvão castle itself within the 50-year statelet, or wilāya - established from 884 to 930 - controlled by Ibn Marwán, his son, grandson and great-grandson from Badajoz.
With the Marwán dynasty possessing siege-ready castles such as this, and also engaged in realpolitik with the Asturian kings in times of conflict (a key ally being Alfonso III of Asturias), there was little to be gained for the Emirate from bringing this particular rebellious marcher-state into the fold.
The Umayyad Caliphate heralded a century of economic boom, maturity in governmental structures, and cultural splendour in al-Andalus, which collapsed only in the year 1008 (finally dissolving in 1031).
The São Mamede mountains around Marvão are likely to have benefited during the 10th-11th century alongside the rest of al-Andalus: population increased as hamlets (aldeias) of smallholdings expanded from villas (although, in Marvão, never reaching the levels of Roman Ammaia); new shepherding pathways (karrales) criss-crossed Roman roads (calçadas), providing the dense network of mountain pathways seen today; irrigation technology and land-terracing improved, notably using gravity-flow water chutes (as-sāqiya); new crops (e.g. the doñegal fig, mulberry for silk production, citrus trees) and farming knowledge enabled more summer harvests and diversification away from the traditional vine, olive, cork oak and fig; Jewish and Christian communities were allowed considerable freedoms; some immigration occurred, with increases in the numbers of Berbers and Slavs (saqaliba, from central Europe - a notable Slav, Sabur, would be the first ruler of the taifa of Badajoz), deemed caliphate 'loyalists'.
Notably, the short-lived Taifa of Lisbon (1022-1045) was to challenge Aftasid dominance in Badajoz along the traditional land trade routes linking the Tagus through the São Mamede sierra (Santarem-Caceres).
An Algarve-centred rebellion by a Sufi sect, the al-Muridin - aided by Almohad arms - destabilised the region and set up a number of 'second taifa kingdoms' in Silves, Mértola and Tavira in the south.
As well as being on the front line against the Christians, the São Mamede mountains are likely to have been on the northern edges of troop movements by the al-Muridin leader, Ibn Qasi and Almohad forces, against Almoravid centres of government (from 1146 to 1151).
The fledgling state of Portugal curried favour with the military orders - the Templars and the Hospitallers in particular - and, through its blood connections with the house of Burgundy, gained support from fortune-seeking crusaders from across the Pyrenees.
Besides Alfonso I's actions in the Tagus valley, a particular destabilising factor in the Alto Alentejo and Extremadure were the exploits of the colourful 'Portuguese El Cid', Geraldo Sem Pavor (Gerald the Fearless).
While Marvão is not listed among Geraldo's many attacks on fortresses in this region, his and Alfonso I's encroachment on Leonese reconquest targets led Ferdinand II to campaign in the immediate vicinity of the São Mamede.
Thus Ferdinand II conquered the vital Tagus crossing at Alcántara in 1165, and this campaign would ultimately define the western limits of Portuguese reconquest, establish the river Sever east of Marvão as a key section of the Portuguese-Spanish border.
In 1190, a major Almohad counter-offensive launched from Morocco under Abu Yusuf Ya'qub al-Mansur retook Marvão, during a campaign against the Templar stronghold of Tomar which would recapture for the Moors much of the Algarve and the Alentejo as far as the castle at Alcácer do Sal.
Following its conquest by Alfonso I in the 1160s, and its brief recapture by Almohads in the 1190s, Marvão's situation remained fragile around the start of the 13th century: it was listed among Portuguese territories only in the termo of Castelo Branco in 1214.
Yet it was the famous Christian victory over the Almohads at Navas de Tolosa (near Jaén) in 1212 - leaving 100,000 Moors dead - that would effectively secure this area of south-western Iberia, and establish a lasting peace.
Another aspect of 13th century statecraft that would bolster the area's 'Portugalidade' (Portuguese identity) would be the settlement of planted Christian colonists from the north (Galicia, the Minho), southern France and Flanders in territories around Marvão.
The resettlement of barren areas depopulated by centuries of warfare and bloodshed - or simply abandoned by fleeing Berber refugees - was vital to sustain the new Portuguese kingdom.
[31] In 1232, Sancho II of Portugal donated further extensive domains south of the Tagus around Marvão and Portalegre to the Knights Hospitaller, along with the duty to fortify the frontier and help in its repopulation.