De facto, it was, since every German state had its own „state song“, some of them still extant. The Wiki article on it is okay
https://en.wikipedia.org/wiki/Heil_dir_im_Siegerkranz
Yet under Nazi Germany, these words came to express German superiority and domination of other countries. That was how two Europeans I knew thought of it due to living through Nazi occupation. That acquired meaning makes the traditional first stanza of the "Deutschlandlied" forbidden in polite society in Germany and throughout Europe today.
That gets me to a funny story. As a student at Tulane University in 1970s, I went with a date to see "Casablanca" at a movie house in the French Quarter. You will recall the scene where Major Strasser and a table of fellow German officers in Rick's begins to sing the "Deutschlandlied."
In response, Resistance hero Victor Lazlo (Paul Henreid) starts up the band and sets the crowd signing "La Marseillaise," drowning out and humiliating the Germans. As this was happening on screen, a few seats from me and my date a small, thin elderly man in a beret stood up and joined in with a clear and rousing voice and finished by shouting "Vive La France!"