Prussia was challenging Austria for the leadership over the German Confederation., and to take administrative power over both Schleswig and Holstein. The war was between Prussia, which was against Austria, Bavaria, Saxony, Hanover, and other minor German states.