Nestled within the southern section of the Shirvan Dynasty Palace Complex lies a remarkable example of medieval architecture: the Seyid Yakhya Bakuvi Mausoleum, often referred to as the “dervish” mausoleum. This sacred site serves as the final resting place of Seyid Yakhya Bakuvi, a distinguished scholar who was part of the court of Khalilulla I. Born in the historic city of Shamakhi, Seyid Yakhya was a devoted follower of Sufism and an esteemed author of numerous religious texts. He passed away in 1464 and was interred within the grounds of the palace complex.
The mausoleum is characterized by its striking octahedral shape, topped with an elegant octagonal hipped dome. Its façade features three small windows adorned with intricately designed stone lattice work, known as shebeke, allowing light to filter into the interior. Beneath the mausoleum lies a burial crypt, which is situated in the basement. The above-ground portion of the structure was utilized for various rituals and ceremonies, making it a significant site for spiritual gatherings.
Inside, the mausoleum boasts beautifully crafted ornaments and vibrant colored stucco, enhancing its spiritual ambiance and aesthetic appeal. Historically, the mausoleum was connected to the ancient Keikubad Mosque, named after the Shirvanshah Kekubad from the 14th century. It was within this mosque that Yakhya Bakuvi engaged in prayer, teaching, and scholarly pursuits. Unfortunately, in 1918, the mosque was destroyed by a devastating fire, leaving only its foundation as a testament to its former glory.