The Pir Husayn Khanqah and Mausoleum lies along the left bank of Pirsaat River (Pirsaatçay), 126 kilometers to the southwest of Baku on the old caravan road to Salyan and 16 kilometers from the Haciqabul railway station. The inscriptive plaque over the portal, read by V. Kratchkovskaya in 1952, announces that the khanqah (dervish monastery) was built by Sharaf al-Dawla wal-din Hasan during the reign of the Shirvan Shah Warajam Afridhun Abul-Muzaffar Fariburz (Fariburz III, 1225-1255). The tile frieze of the tomb, assembled by Kratchkovskaya at the State Hermitage Museum, gives a later date: "Here lies the sheikh, imam, mystic...Al-Husain, son of 'Ali, known as Pir Husain Rawanan...His tomb was rebuilt by 'Umar, son of Muhammad al-Shirzadi of Qazvin and completed in the year of 684 [1280 B.C.E.]." It is likely that the tomb of Pir Husayn bin Ali, an Azeri sheikh of the Qalandariyya sect who lived in the tenth or eleventh century, existed on this site before a formal khanqah was built around it in the thirteen century. His mausoleum is often misidentified as that of Pir Husayn bin Sa'ad, a local ruler of the Turkmen Qara Qoyunlu dynasty that dominated the region from 1351 to 1469. The minaret of the complex bears an inscription signed in 1256 by master builder Mahmud bin Mes'ud. Only part of the ramparts, the minaret shaft and foundation walls of the courtyard structures remain of the khanqah today.
Built out of cut-stone, the roughly rectangular complex was centered on an open courtyard fortified with ramparts, similar to a ribat. The crenellated rampart walls were buttressed with round bastions at the corners and semi-circular bastions at the middle of the south, east and west walls. A monumental gate centered on the eastern wall gave access to the courtyard, which was surrounded with halls of different sizes to its north and west, including a mosque on the western wing and a single minaret near the northeastern corner. Photographed in 1907 by S. Ter-Avetissian, the portal consisted of an arched entryway bearing a four-line inscription in naskhi script, with only the pointed archway remaining of its upper floor. The octagonal tomb of Pir Husayn stood along the southern wall, adjoined by a single cell.
Built along the western rampart wall, the khanqah mosque was about eleven meters long and five meters wide by on the interior. It was entered through a portal centered on its eastern wall. Its damaged stucco mihrab, which is now on view at a Baku Museum, is crowned with an inscriptive plaque in naskhi script and framed with a band of floriated Kufic inscription. The cylindrical minaret of the mosque, which also functioned as an observation tower, was elevated on a square cell and an octagonal base. It had two inscriptive plaques on its lower shaft, and an inscriptive band along the balustrade of its muqarnas balcony. Its narrower upper shaft was crowned with a dome in the style of Baku minarets.
The Pir Husayn Khanqah is renowned for the glazed tiles covering the interior of the tomb and the sheikh's sarcophagus, which had disappeared entirely by 1913. By the 1940s, more than four hundred of the tomb's cross and star-shaped tiles were identified by V. Kratchkovskaya at the State Hermitage Museum (St. Petersburg) and the State Museum of Georgia (Tbilisi), including tiles from the inscriptive frieze of the mausoleum. Set in an array with plain cross-shaped tiles, each eight-sided star tile featured a unique composition of floral motifs and depictions of birds, horses and fish painted on a turquoise base and bordered with a single line of inscription on a white background. Given the absence of ceramic workshops in Shirvan Shahi territory in the thirteenth century, it is likely that the tiles were made by Persian artisans from Kashan or Tabriz.
Aslanapa, Oktay. 1979. Kirim ve Azerbaycan'da Türk Eserleri. Istanbul: Baha Matbaasi, 84-92.