The Bavarian Army was the army of the Electorate (1682–1806) and then Kingdom (1806–1919) of Bavaria. It existed from 1682 as the standing army of Bavaria until the merger of the military sovereignty (Wehrhoheit) of Bavaria into that of the German State in 1919. The Bavarian army was never comparable to the armies of the Great Powers of the 19th century, but it did provide the Wittelsbach dynasty with sufficient scope of action, in the context of effective alliance politics, to transform Bavaria from a territorially-disjointed small state to the second-largest state of the German Empire after Prussia.