The history of the Kloosterkerk starts around 1400 AD. In 1393 the land on which the present church has been built by Count Albrecht van Beieren (Count of Holland, Zealand and Hainaut), was donated to the St Andriesklooster in Amsterdam in order to build a monastery on it. In 1394, however, the people of the monastery sold the land to the lord van Arkel, who built a town castle on it. In those days many castles could be found in this area. At the end of the fourteenth century, however, all of them had been demolished. In 1401 the lord van Arkel came into conflict with Count Albrecht van Beieren. He had the lord’s entire property confiscated, including his castle, which was razed to the ground. This time the land was donated to the Dominican monks from Utrecht, who did built a monastery on it. The strong bonds between Margaretha van Kleef, wife of Count Albrecht, and this Dominican order played an important part in the allocation of the land. When she died, Margaretha van Kleef was buried in the Kloosterkerk. In 1420 a fierce blaze raged through the monastery.
The fact that the States of Holland kept their documents in the monastery for decades, indicates how big the building must have been. The church, however, was considerably smaller than it is today. It was enlarged around 1540 AD, some 140 years after it had been built.