Sultan Mustafa III (1717-1774) had the Ayazma Mosque, which rises between the Salacak and Şemsipaşa districts of Üsküdar, built by the architect, Mehmed Tahir Ağa, in 1761. In addition, the mosque, which features predominately Western style architectural aspects, was built in memory of his mother Mihrişah Emine Hatun and his elder brother Şehzade Süleyman. It is understood from certain sources that the name of the mosque comes from the Ayazma Palace which had once been located on the site.
The Ayazma Mosque has been renovated several times during its lifetime. A new minaret has been built twice on the site of the demolished minaret. The muvakkitkane (time-keeping room) and the bath, which was built to generate income for the mosque, as well as many stores of the mosque have not reached the present day. The mosque, which is placed in the middle of a wide field, is located on a hillside overlooking Istanbul. In addition to Western architectural elements, classical designs have added a different complexion to the structure. The main space of the building is built on a rectangular plan and is covered by a dome resting on four elephant legs. The Hünkar Köşk (Royal residence) of the building, built next to the mosque, is situated on the left hand side of the main site. A variety of colourful stones are used to decorate the sermon area, the niche, and the pulpit of the mosque. Decorations with gold latten are used in the royal residence and are the creation of highly skilled craftsmanship. Furthermore, the pulpit, composed of colourful, engraved marble stones, as well as the niche, made of porphyry stones, are further reflections of the skilled workmanship of the building. The scripts on the portal gate belong to the calligrapher, Seyyid Abdullah, and scripts on the plaster windows belong to calligrapher, Seyyid Mustafa.
There is a fountain located on one corner of the wall surrounding the courtyard of the Ayazma Mosque that was built during the same year with the mosque. The inscription written on the fountain belongs to the poet, Zihni.There are graves of several notable individuals of the Ottoman Palace in the mosque’s graveyard.