In 1742 Shemakha was taken and destroyed by Nadir Shah of Persia, who relocated inhabitants into a new town under the same name about 16 miles to the west (Agsu) , at the foot of the main chain of the Caucasus. The new Shemakha was a residence of the Khans of Shirvan. Smaller Old Shamakha khanate continuned to exist under Muhammad Sa'id Khan (1748-1786) until the merge of the two. After the merger the New Shamakha finally abandoned, and the old town rebuilt in 1786. During 1768-1778 Shirvan khanate was a dependency of much stronger Quba Khanate. In 1795 Russians captured Shemakha as well as Baku; but the conquest was once more abandoned, and Shirvan was not finally annexed by Russia until 1805. Tomb of Nadir Shah, a popular tourist attraction in Mashhad Nadir Shah (Nadir Qoli Beg, also Tahmasp-Qoli Khan) (October 22, 1688 - June, 1747) ruled as shah of Iran (1736â47) and was the founder of the short-lived Afsharid dynasty. ... Quba Khanate was independent principality on the territory of modern day Azerbaijan between 1747 and 1806. ... Shemakha is a town in Azerbaijan, 70 miles west of the national capital Baku, and in 40 38 N. and 48 40 E. It has some 20,000 inhabitants, formerly consisting of Azerbaijanis (75%), Armenians and Russians. ... Satellite view of Baku The Baku harbour on the south of Absheron peninsula The Maiden Tower in old town Baku Baku (Azerbaijani: Bakı), sometimes known as Baky or Baki, is the capital of Azerbaijan. ...