The municipality of Markina-Xemein includes two population entities: the town of Markina and the district of Xemein. Since 1969 the municipal district of Zenarruza with its town of Bolibar was included in the same municipal area. This district obtained the detachment of Markina-Xemein on January 1, 2005.
The oldest testimonies of the municipality belong to the Paleolithic and Eneolithic-Bronze Age, opening after these stages a silence that will last until the 10th century when the small religious nucleus of Iturreta arises.
In the 14th century, year 1355, the Infante Don Tello, Lord of Vizcaya and son of Alfonso XI of Castile, founded the Villa de Villaviciosa de Marquina. This town owed its name to being a landmark or border with Gipuzkoa. It was founded at the request of the residents of the Merindad to defend themselves from the attacks of the powerful Gipuzkoan families. Many rural noblemen came to the villa fearful of the armed incursions of the bannermen (warlords).
After the founding of the town, there were no shortage of lawsuits and controversies with the neighboring districts of Xemein and Etxebarria. These lawsuits were caused by jurisdictional reasons that ended in the seventeenth century.
In the eighteenth century there was an uprising in which the neighbors requested a reduction in the price of cereal. In the same century, on the occasion of the War of the Convention (1793-1795) the population was constantly organized.
The Napoleonic invasion and the Carlist Wars marked the history of the 19th century, with Markina becoming the crossroads of the fighting armies. Although it was not a war scene, the municipality had to be organized and defray the expenses involved in supplying the troops. The town was also witness to continuous bombings during the civil war in 1937.