Originally a settlement by groups such as the Romans and the Visigoths, its previous name was Civitas Pacensis. Badajoz was conquered by the Moors in the 8th century, and became a Moorish kingdom, the Taifa of Badajoz. After the reconquista, the area was disputed between Spain and Portugal for several centuries with alternating control resulting in several wars including the Spanish War of Succession (1705), the Peninsular War (1808–1811), the Storming of Badajoz (1812), and the Spanish Civil War (1936). Spanish history is largely reflected in the town.