Its foundation dates back to the years 1678 – 1681. Initially, both the Lutherans and the Catholics were able to attend the Marian Basilica; the Lutherans prayed at the St. Nicholas’ altar, while the Catholic parish priest conducted masses at the main altar. However, near the end of the 16th Century, the Protestants occupied the entire building, while the Catholics were force to squeeze into the rooms of the rectory. This church, with its unique shape and central arrangement, was built for the needs of the Gdańsk Catholics, who needed a place to house their community, resurrecting in the city after the Lutherans deprived them of the right to services in the Marian Basilica.
During the visit of King John III Sobieski in 1677, the primate Andrzej Olszewski died in Gdańsk. His will contained 80 thousand zloty for the new chapel. The King added 20 thousand from his own treasury, thus allowing the beginning of the construction of the new chapel, deemed Royal in his honour.
The chapel was built on the area adjoining the rectory from the direction of Św. Ducha Street, in the place previously hosting 5 tenement houses owned by the church. The construction work lasted three years and was completed on 10 May 1681. The author of the project was Tylman von Gameren, the court architect of John III Sobieski, while the interior was designed by Andreas Schluter the Younger.
In 1945, the interior of the chapel was burned down, while the walls of the western tenement were destroyed right down to the ground floor. The only preserved elements of the pre-war decorations were the 19th-Century frescos under the cupola. The chapel was restored during the years 1946-48, the tenements were reconstructed in 1970, and the restoration project and complex conservation of the facades and roofs took place in 1995.
The Royal Chapel, which was renovated a few years ago, is best presented from the direction of Grobla Street, which is the location of the cartouche with the Polish national emblem and the Janina – the coat of arms of King John III Sobieski.