Originally built as a bathhouse for the powerful aristocrat Stanisław Herakliusz Lubomirski, on an island in the middle of a lake by Tylman van Gameren in 1772. It was completely rebuilt between 1764 and 1795 by Domenico Merlini for King Stanisław August Poniatowski to serve as his private residence. The palace was built on an artificial island that divided the lake in two parts: a small northern lake and a large southern lake; it is connected to the surrounding park by two Ionic colonnaded bridges. An extra storey was added to the southern part of the palace in 1775. In 1784, Merlini designed a new south facade and in 1788, the wings were added to the palace, making room for the ballroom, the Salomon Room and a gallery. A facade was also erected on the north side, which has a stern, monumental look. In 1792, the palace was expanded with both pavilions on the edges of the colonnades connecting to the main building.