"Hej, Sloveni!" (Hey, Slavs) is a patriotic song written by Samuel Tomášik in 1834. It served as the national anthem of Yugoslavia from 1943 to 1991 and later was adopted by Serbia and Montenegro until 2006. The melody is based on Mazurek Dąbrowskiego, the Polish national anthem, and became an anthem of the Pan-Slavic movement.