Sher Shah defeated Humayun in the battle of Kanauj in May 1540 and became the new ruler of northern India.
When Humayun was in Persia, Kamran offered the Shah the city of Kandahar if he would hand his brother over to him.