The Free State of Bavaria (German: Freistaat Bayern, Alemannic German: Freistaat Bayre, Bavarian: Freistood Boajan/Baijaan, Main-Franconian: Freischdood Bayan; Czech: Bavorsko) is a federal state of Germany. In the southeast of the country with an area of 70,548 square kilometres (27,200 sq mi), it is the largest state, making up almost a fifth of the total land area of Germany, and with 12.5 million inhabitants is Germany's second most populous state. Munich, Bavaria's capital and largest city, is the third largest city in Germany.
The History of Bavaria stretches from its earliest settlement and formation as a duchy in the 6th century through the Holy Roman Empire to becoming an independent kingdom and finally a state of the Federal Republic of Germany.
The Duchy of Bavaria dates back to the year 555. In the 17th century, the Duke of Bavaria became a Prince-elector of the Holy Roman Empire. The Kingdom of Bavaria existed from 1806 to 1918, when Bavaria became a republic. In 1946, the Free State of Bavaria re-organised itself on democratic lines.