Church Slavonic originated as a literate language when the missionary Constantine (later called Cyril) in the ninth century devised an alphabet for the spoken language of the Slavs of Great Moravia. Cyril and his brother Methodius used the alphabet to prepare translations of liturgical books for use during their mission preaching Orthodox Christianity to the Slavs of Moravia. His original alphabet was called Glagolitic. The Glagolitic alphabet was later, in the tenth century, refined into the alphabet called Cyrillic.
In preparation for their mission to preach Orthodox Christianity to the Slavs of Moravia Cyril, with his brother Methodius, in 863 created the Glagolitic alphabet based upon the Slavic dialects of their home, Thessalonika. This alphabet was used to prepare translations of some of the Holy Scriptures and church services books. After about two years of use in the Moravian Academy and in government and religious documents, Papal prohibitions in 865 banned use of Slavonic in favor of Latin in Moravia and the pupils of the missionaries were expelled from Moravia the following year.
Those who were expelled brought the Glagolitic based literary language south to the Bulgarian Empire where it was placed in use in the Preslav and Ohrid academies. In time the refined Cyrillic alphabet replaced the Glagolithic alphabet. As the language represented by the Glagolitic and Cyrillic alphabets remained the liturgical language of the Orthodox services as local vernaculars came into use the name Church Slavonic became applied to the language. As the original language, now called Old Church Slavonic, spread throughout the Slavic world local redactions were created for ecclesiastical and administrative use and this Cyrillic based language became known as Church Slavonic. Church Slavonic continued as the common liturgical language of the Orthodox Churches of the Slavic area including the Russian, Bulgarian, and Serbian churches even as the common spoken languages of the people changed.
In the middle European Slavic areas, the use of the spoken Slavic languages and dialects began to replace Church Slavonic in secular documents about the 15th century. Church Slavonic remained the literary language in Russia until the 17/18th centuries and was generally not spoken outside of church services. From the 17th century on the Russian language began replacing Church Slavonic in secular literature, although usage of Church Slavonic continued among the Old Believers much longer.