The builder of the Sternberg Palace was Count Václav Vojtěch of Šternberk. After 1698, probably according to his own project, the construction was taken over by Giovanni Baptista Alliprandi, who completed the existing northern four-wing building by Šternberk's death. The built palace represented less than a third of the ambitious design. However, the descendants of the Earl did not continue in the completion of the palace, whose main facade was to be opened on Hradčanské Square. The palace remained in the possession of the Counts of Šternberk until 1811, when it was bought by the Society of Patriotic Friends of the Arts, the predecessor of today's National Gallery, which had its seat here until 1871. Since 1948, masterpieces from the collections of the National Gallery in Prague have been exhibited.
The Sternberg Palace together with its garden is currently closed due to revitalization. It will reopen to the public with the new permanent exhibition Old Masters II.