The Russo-Persian War of 1651–53 was an armed conflict in the North Caucasus, associated with the Safavid plans to strengthen its position in the region and to exclude Russia. Safavid troops and allies (wali [governor] of Dagestan, Khan of Derbent) made several campaigns to the lands partly controlled by Russia, and destroyed the Cossack fortress on the middle Terek River, while expelling its Russian garrison. In 1653 Alexis of Russia and the Russian government, which thought about sending the Russian Zaporozhian Army, but did not want to disperse its forces, sent an embassy to Persia for a peaceful settlement of the conflict. Shah Abbas II agreed, stating that the conflict was initiated without his consent.
From the 1520s there had been Cossacks on the Terek River. They were more-or-less controlled by the Russian governor at Astrakhan, the intervening land being nomad country. South of the Terek in Dagestan were various khanates who recognized the supremacy of Persia. The main Cossack town was Terki on the lower Terek. The Cossack towns had local allies who were a major part of their military force. In 1634 they built a new fort on the lower Sunzha River near the modern city of Grozny, in support of the Georgian ruler Teimuraz I, who had been deposed by his Safavid suzerains and had turned to the Russians for aid. The immediate pretext was the plundering, by a group of Cossacks, of a caravan belonging to the Khan of Shamakhi. He demanded compensation from the Astrakhan governor and threatened to eliminate both the Cossacks and Astrakhan.
First campaign: In 1651 the Shamakhi Khan received a decree from the Shah telling him to destroy the Sunzha fort and march on Astrakhan. 12,000 men were gathered from all over Dagestan along with 800 Persian regulars. They marched to the Sunzha River. Between 25 October and 7 November there were a number of battles which the Russians won. After looting the surrounding country the Dagestanis withdrew, taking with them thousands of horses, cattle, sheep and camels as well as human captives.