The village has existed since Phoenician and Roman times, and its municipal boundaries stretch from the sierra of the same name to the banks of the River Guadalhorce, most of the area within them being devoted to agriculture, notably olives, almonds, fruit and vegetables.
Monuments of interest include St. Peter’s Church and Virgen de los Remedios Chapel, the latter, built on the site of a former mosque, attracting pilgrims from all over the region.
The Phoenicians settled alongside local tribes and gave the settlement the name "Cartha", meaning "hidden place".
The Romans later christened the village "Cartima", fortifying the location which, standing atop a rugged hill 427 metres in height, provided a magnificent natural vantage point offering views of part of the Guadalhorce Valley to the north. The Roman town of Cartama was one of the most important in what is now the province of Malaga, already enjoying official town status in 195 B.C.
Cartama was also important during the Moslem occupation, given the strategic nature of its location and the fertility of the surrounding land. The Arabs renovated and rebuilt the fortress, turning it into one of the finest military bastions in the area.
It was captured by troops under the Catholic Monarchs in 1485. This conflict was immortalised by the Mozarabic wood carvers responsible for the bas-reliefs which adorn the choir of Toledo Cathedral, which can still be seen today.
Within the municipal boundary stands the district of Casapalma, once the property of the Count of Casapalma, until an 1811 decree saw it added to Cartama.