Given that Denmark was a victim of Prussian expansionism
How can I forge an alliance between Denmark and the German Empire.
After the formation of the Empire, and before the first world war.
in the 1864 2nd Schleswig War as part of the formation of the Prussian Empire a genuine
alliance is unlikely
However if Prussia has pursued a more vigorous campaign then Denmark might well have been reduced to the kind of
client state that Austro-Hungary had become after it's defeat by Prussia a couple of years later.
Fortunately for the Danes, such overt action, with the effect of taking control of the Baltic Narrows, would have alerted the British to the Prussian danger. At that point Britain's neutrality was vital to the Prussians and they were relatively ... only relatively, of course ... merciful avoiding British aggravation.
If they had pushed harder, Britain might sought an early "Entente" with Napoleon III, despite the traditional British view of the French as "the ancient foe" and the family ties between the palaces in London and Berlin.
If such had been the case, the the Great War might have been fought a generation earlier but been confined between the Rhine valley & the Low Countries
Denmark's suffering might have been balanced by a gain to the whole of Europe, indeed the world