The name Ali Qapu, meaning "Magnificent Gate", was given to this place as it was right at the entrance to the Safavid palaces which stretched from the Maidan Naqsh-e-Jahan to the Chahar Bagh Boulevard. Built at the very end of 16th century, the royal palace was used to entertain noble visitors, and foreign ambassadors. Ali Qapu is 48 meters high and has got five floors, fronted with a wide terrace whose ceiling is inlaid and supported by wooden columns. It offers a wonderful perspective over the square and the best view of Imam Mosque. The interior of the building is decorated with naturalistic scenes by Reza Abbassi, the renowned Persian miniaturist and painter. On the upper floor the music room is also decorated with plasterwork, representing pots and vessels.