The Afghans were the most formidable rival of the Mughals in India. The Afghans could not reconcile themselves to the defeat they had suffered in the first battle of Panipat (1526). Hence a new chapter of the Mughal-Afghan contest begun from the very moment, the battle ended. The contest continued for long thirty years till Akbarb.
Second Battle of Panipat:
However, the first battle of Panipat. Though weakened the Afghans considerably, could not take away the vitality in them. Once again the Afghans appeared in fill strength under the able leadership of Sher Shah to strike the Mughals.
The Afghans got a new lease of life under Sher Shah who inflicted a crushing defeat upon the Mughals, then under the leadership of Humayun, the son and successor of Babur.
The real motive of Sher Shah behind his struggle against the Mughals was to wrest the political power from them.
In fact, being defeated by Sher Shah, Humayun had to flee from India to take shelter in Persia. In the second battle of Panipat Himu (Vikramjit), the chief adviser of Adil Shah was defeated by Bpirum Khan.