The church is the oldest building in the town and was built in place of a small wooden church consecrated to Sv. Mikuláš in the first half of the 13th century. From the 13th century, the church was complemented by a vicarage and Oldřich of Sulzbach was the first priest there. It is remarkable that he soon became the first Chaplain of Queen Eliška and a copy writer to the Archbishop. Another important priest working here was Křišťán of Prachatice who became a university teacher and later also the Principal of Charles University. In the course of the 15th and 16th centuries the religion of this area changed to Calixtine, and therefore also the Calixtine communion. Towards the end of the 16th Century, the Lutheran religion prevailed here.
On 30th May 1567 the whole of the town was engulfed by fire. Also the church was destroyed and repair works were tackled almost immediately. However, money soon ran out, which is demonstrated by the fact that the height of the presbytery was not in the right proportion to the height of the church which impaired the overall look of the church which was rectified as late as in 1857. Despite the fact that the Lutheran religion was popular here, there was a group of Catholics who were led by Štěpán Beník of Petrsdorf. The groups forced a permission to build a Roman Catholic Church with a monastery in Jílové. This church was established in 1623 when there was no point to build since majority of people had turned back to Roman Catholicism. The church was consecrated to Our Lady of Loretta and run by the Minorite Order. In the 18th century of the process of re-catholisation was completed and everybody allegedly professed Roman Catholicism. In the course of the 17th and 18th century the church was repaired repeatedly and given a Baroque style character. A chapel of Sv. Anna was added to its south, the spire was repaired in 1791 and a golden cupola added. Electricity was installed in 1901 and a few years later it was necessary to repair the masonry of the church and therefore the church was repaired from both outside and inside. Between 1990 and 1999 more thorough repairs were performed. The static condition of the spire was secured because its weight was crushing the masonry at the bottom of the spire. The total cost of the repair reached almost two and a half million CZK.
The interesting aspect of the church is that the spire stands between the presbytery and the nave. Thanks to this architectural interesting feature and also thanks to the beautiful Gothic style altar, the church was chosen as one of the locations for the film Amadeus and several sequences were shot there by Miloš Forman in 1983. There are five Baroque altars including the altar which was transferred here from the later closed Loretta Church, and a modern altar that was sanctified on 6th November 1999. The most important piece of the church interior is a Gothic tabular altar from 1485 which was purchased by the above mentioned Štěpán Beník of Petrsdorf and was brought here from St. Wenceslas church in Prague - Zderaz. One of its paintings was painted by a significant Czech artist Petr Brandl. Also the 16th century tin baptismal font and the nave-bell, death bell, noon bell, middle bell and big bell should be mentioned. The big bell weighs 1,394 pounds which is approximately 700 kg and its name is Vojtěch.