The melody of the "" was originally written by Joseph Haydn in 1797 to provide music to the poem "Gott erhalte Franz den Kaiser" ("God save Franz the Emperor") by Lorenz Leopold Haschka.
The same melody was later used by Haydn as the basis for the second movement (poco adagio cantabile) of his Opus 76 No. 3, a string quartet, often called the "Emperor" or "Kaiser" quartet.