After Austria was defeated in the Austro-Prussian War of 1866 and the German Confederation was dissolved, the Austro-Hungarian Compromise of 1867 was adopted. By this act, the Kingdom of Hungary and the Empire of Austria as two separate entities joined on an equal basis to form the Dual Monarchy of Austria-Hungary.