the cart drawn by the horses from the street could enter the second floor of the palace. After making the above-mentioned reorganization, the military department attached a ladder to the eastern facade of the palace, and the entire southern (or lower) courtyard was surrounded by a stone wall with loopholes. This wall was erected from a foundation left from the old walls surrounding the palace. The palace ensemble is now protected by fortress walls erected in the first half of the 19th century. During existence of the Azerbaijan Democratic Republic (1918–1920), a number of measures were taken to study and fix architectural monuments. Thus, at the end of 1918, the dimensional drawings of the Shirvanshahs Palace were made by the Ishmael Bek Nabi oglu, the architectural engineer. At the beginning of 1920, several cycles of lectures on the fate of the palace were read in the "Society for the Study of the Muslim East" by Ismail bek Nabi oglu. The periodical press indicated that the report was illustrated by various photographs and drawings of the palace. After the reports and debates, the presidium of the society was elected, which included chairman Professor Zimin, Comrade chairman I Belyaev, secretary-teacher Seidov and Kazioni Subkhanverdikhanov. The meeting instructed the presidium to organize an excursion to the palace in the near future. In 1920, the government of the Azerbaijani SSR began to take measures to protect the monument. Since 1920, the cleaning of the palace from the age-old layers of garbage and partial repairs began, accompanied by archaeological reconnaissance. In 1924 the works were continued. After the extensive repair and restoration works of 1932–1934, conducted by AzCUOP together with the Moscow State Restoration Workshops for projects designed by architect Boris Zasypkin, the building of the former Shirvanshah palace was given to the Azerbaijan History Museum AzFAN. Since the clay floors were fragile, and the building of the palace was intended for the organization of a museum in it, during the repair and restoration work the floors were covered with parquet. Also during the works from the window openings were laid the stones laid in the 19th century, and they were returned to their original appearance. The original layout of the second floor was not restored, due to the fact that the premises were supposed to be a museum: where there are only two rooms, there were originally eight rooms. The plan of the first