Sabayil Castle Sabayil Castle is a castle in Baku , Azerbaijan , on the coast of the Caspian Sea . The castle is named after the surrounding area - Bayil . The structure is also known the " Atlantis of the Caspian Sea " . Research scientists have referred to it as “ Sabayil castle ” , “ Bayil castle ” , “ Bandargala ” , “ Underground town ” , “ Caravanserai ” , “ Cloister ” , “ Monastery ” , “ Custom house ” and “ Defence castle ” . History . The castle was built on one of the Bayil hills near the Caspian Sea coast from 1232 – 1233 , during the life of Shirvanshah Garsasb ’ s son Fariburz . The architect was , Abdul - Majid Masud oglu . At the same time , in 1232 , this architect also built the round castle in Mardakan , which was part of Abseron ’ s integrated defence system , defending the city and Bayil Castle from the north . During a major earthquake that rocked Baku in 1306 , the building collapsed and the island submerged and remained under water for several centuries . It was only in the early 18th century , when the Caspian Sea retreated , that the island resurfaced . According to Sara Ashurbeyli , a well - known Azerbaijani historian , Sabayil is the castle mentioned by Abdurrashid Al - Bakuvi , a 15th - century geographer who said that the castle was destroyed during the 13th - century Mongol invasion . Al - Bakuvi , a native of Baku , wrote in 1430 in his " Kitab - talkhis el - asar ve el - melik el - gahhar " : " Baku has two castles , very strong , built of stone . One of them is very large and on the shore Maiden ' s Tower . This is the castle that the Mongols could not conquer . The other is further offshore . Its upper parts have been destroyed . " Architecture . The building complex , which is 40 metres long and 180 metres wide , consists of 15 semi - circular castles , 16 to 28 metres apart and connected by a wall . One of the castles at the four corners – the northern one – stood alone , but the others were connected via small cells . The wall was between 1 . 2 and 1 . 5 metres thick . On the wall there were individual stone panels with frieze inscriptions ( 70 cm long , 25 – 50 cm wide and 12 – 15 cm thick ) . In 2008 an ancient underpass , dated back to the 19th century , was discovered in the Walled City of Baku . According to scholar Vitaly Antonov , this passage is one of the several , leading to the ancient Sabayil Castle . There are several underground tunnels leading from the Palace of Shirvanshahs and Synykh Gala , situated in Icheri Shekher , to the sea . Synykh Gala was the mosque in the 15th century , in the times of the Shah Ismail Khatai , and was destroyed by the troops of Peter I . That is , the discovered passage is part of the underground network connecting the city of Sabayil to the land . Relics . From 1939 - 1969 , an archaeological expedition organized by the Institute of History of the Azerbaijani Academy of Sciences , led by Prof Y . Pakhomov and archaeologists I . Jafarzade and O . Isimzade , discovered relics and , at different times , more than 700 inscribed stone panels . They helped very much to clarify the purpose and the date of building of Bayil Castle . The stones are currently kept in the courtyard of the Shirvanshahs Palace in the Walled City of Baku . They are decorated with frieze inscriptions in Arabic and Persian , chain - shaped ornamentation and images of people , animals , birds and mythical animals . These artworks are valuable in the study of the culture of the Shirvanshah period . However , time and the elements have affected many of them . Up to 30 percent of the stones recovered from the sea had been damaged by the centuries - long work of the waves and their inscriptions and images had been effaced . And not all of the stones have been recovered . The names of fifteen Shirvanshahs and other valuable information were found on these stone slabs by historians . Legacy . Arif Ardebili , a poet of the Middle Ages , noted in his well - known dastan ( epic poem ) " Farkhad - name " the view he had seen : The poet was most likely referring to the Bayil Castle . He saw Bayil Castle after nearly a century it was built . So , for him and his contemporaries the castle was still " new " .