In the first years of Christianity in Lithuania there were no special educational institutions for priests, and the pastoral work was often done by foreigners, mostly Polish. Medininkai diocese wanted to overcome the shortage of priests and in 1469 established a school by the cathedral for future priests of the diocese.

The seminary in Varniai opened only in 1623, when thanks to Stanislovas Kiška two separate wooden buildings were built for the purpose. They were erected upon a hill, where previously pagan rituals had taken place, later two Medininkai (Samogitian) diocese cathedrals were built there. In 1770 a whole seminary palace was built, where future priests studied until 1864, when by the decision of Russian Czar, the seminary was relocated to Kaunas.

Motiejus Valančius entered the seminary in 1822. During the period from 1845 to 1850 the future bishop who was appointed as the rector of the Samogitian seminary began a sobriety movement, took care in educating children and adults, and organised the distribution of Lithuanian books.

The seminary palace remains to this day. When Lithuania regained independence, the discipline company of the Lithuanian Armed Forces and Duke Vaidotas regiment were established there. Later on, the palace was used as a secondary school, technical college, and dormitory. In 1991-1995 the palace’s bell tower and the former (late Baroque style) roof construction were rebuilt. By Resolution of the Government of the Republic of Lithuania in 1999 the palace was passed on to the Samogitian diocese museum.

Next to the palace the M. Valančius garden has survived – the garden planted by the bishop himself, an alley of trees and a pond. It is said, that it was specifically here that he meditated, thought and communicated with the rebels, thus the garden is considered a significant object of cultural heritage.