The roots of the Slovene language, as of other Slavic languages, are connected to the migration of Slavs in the sixth century AD, when three groups of Slavic – Eastern, Western and Southern began to form.
It is considered that the Slovenian language emerged between the seventh and ninth centuries when it separated from Serbo-Croatian. Slovene became more similar to the Kajkavian and Cakavian Croatian dialects and moved away from the Shtokavian dialect upon which modern standard Bosnian, Croatian and Serbian languages are based.
The earliest texts written in distinct Slovene are the Freising Manuscripts, known in Slovenian as Brižinski spomeniki, and are dated between 972 and 1093.
Standardisation of Slovene dates from the second half of the 16th century. In 1811, Slovenian was adopted as the language of education, administration and the media and later became the official language of Slovenia.
From the High Middle Ages until the breakup of the Austro-Hungarian Empire in 1918, in the territory of present-day Slovenia, German was the language of the elite, and Slovene was the language of the common people. During this period, German had a strong impact and modern spoken Slovene retains many Germanic words and phrases.
In the 19th century, the nationalist movement influenced the purification of the Slovenian language by replacing German words with borrowed Czech and Serbo-Croatian words. This tendency reversed later when writers strived to avoid using excessive Serbo-Croatian words.
The impact of Serbo-Croatian increased once again at the time of the Kingdom of Yugoslavia in the 1920s and 1930s.
After World War II, Slovenia became part of the Socialist Federal Republic of Yugoslavia and Slovene was one of the official languages in the federation. The national language was widely used in Slovenia.
After gaining independence in 1991, Slovene was declared the official language of Slovenia.