Boyabat is a town and district of Sinop Province in the Black Sea region of Turkey. The mayor is Mehmet Ermiş (AKP). Boyabat has a population of 50,000 in the town itself. The town is in the Gökırmak ("blue river") valley, a river valley parallel to the Black Sea coast, located 100 km south of Sinop over the coastal mountain range, Isfendiyar Mountains. The town is the trade hub for over a hundred villages around it. Of larger centers nearby, up the Gökırmak valley to the west are Taşköprü, and Kastamonu; down the Gökırmak and later Kızılırmak ("red river") valley to the east you find Durağan, Havza, Vezirköprü, and Samsun. Name The name Boyabat is said to consist of "boy" which means border and the Persian suffix "abad" (آباد) which means built/cultivated town/agricultural landscape. It bears witness to the fact that the border between the Byzantine empire and the empire of the Seljuq Turks was once here. History Boyabat town was built below an imposing castle which probably has not been in serious use since around 1300 A.D. but may be as old as 2800 years. Kazdere/Gazidere, a tributary of Gök River, passes through the town. It cuts the rock that the castle is perched on with a dramatic pair of vertical walls. The wall on the castle side has a window on the rock face illuminating descending tunnels to a newly discovered large underground city from Roman times. The tunnels may also have served for water supply and safe passage during siege. The castle overlooks the Gökırmak valley. This valley is long and lies parallel with the Black Sea coast. Together with the similarly placed Yeşilırmak (river) valley further east, it forms a natural east-west pathway used since the antiquity as a trade route, possibly as part of the silk road. The castle may have served to protect this trade route. Being a suitable distance from Durağan, Hanönü and Taşköprü, it may have provided safe stop for caravans. The older history of Boyabat may have started from Bronze Age, and it may have been ruled by Kaskians, Hittites, Paphlagonians, Persians, Lydians, Pontus kingdom, and Romans. It served as a border castle between Lydia (later Roman Empire) and the Pontus kingdom a thousand year before it was again a border between Seljuqs and Byzantians. Since it has been captured a few decades after the Battle of Manzikert (1071) by Gazi