The Kingdom of the Lombards, also known as the Lombard Kingdom and later as the Kingdom of all Italy (Latin: Regnum totius Italiae), was an early medieval state established by the Lombards, a Germanic people, on the Italian Peninsula in the latter part of the 6th century. The king was traditionally elected by the very highest-ranking aristocrats, the dukes, as several attempts to establish a hereditary dynasty failed. The kingdom was subdivided into a varying number of duchies, ruled by semi-autonomous dukes, which were in turn subdivided into gastaldates at the municipal level. The capital of the kingdom and the center of its political life was Pavia in the modern northern Italian region of Lombardy.
The Lombard invasion of Italy was opposed by the Byzantine Empire, which had control of the peninsula at the time of the invasion. For most of the kingdom's history, the Byzantine-ruled Exarchate of Ravenna and Duchy of Rome separated the northern Lombard duchies, collectively known as Langobardia Maior, from the two large southern duchies of Spoleto and Benevento, which constituted Langobardia Minor. Because of this division, the southern duchies were considerably more autonomous than the smaller northern duchies.