Although it has been the tune of the German national anthem, also known as the "Deutschlandlied" since 1922, the familiar tune was, in fact, written both by, and in praise of, an Austrian. Joseph Haydn (1732-1809) composed it in honour of Emperor Francis II and the original words began (in translation) with "God preserve Kaiser Franz". Haydn later incorporated into his "Emperor Quartet".

During the revolutions of the 19th century, it was given different lyrics by the poet Hoffmann von Fallersleben, reflecting the cause of national unity rather than extolling a monarch.

Inevitably, when the Nazis came to power, the anthem was hijacked, and its infamous first verse proclaiming "Deutschland ueber Alles" ("Germany above Everything") became inextricably linked to the evils of the Nazi regime.

After the end of the war, the tune of the national anthem was maintained, but now only the third verse, speaking of "Unity and Right and Freedom" is sung.

The tune is also used for some English hymns, perhaps most famously, "Glorious Things of Thee are Spoken".

More Info: en.wikipedia.org