In 1465, Akhmat seized power in the Horde by rising against his brother Mahmud Khan, who had been its ruler since 1459. In 1472, Akhmat entered into alliance with the Polish king Casimir IV against Ivan III. In 1476, Akhmat suggested to Ivan III that he should recognize Russia's vassal dependence from the Horde. However, the correlation of forces was not in the Horde's favor. In 1480, Akhmat organized another military campaign against Moscow, which would result in the Horde's defeat (seeGreat standing on the Ugra river). Russia finally freed itself from the Tatar-Mongol oppression.