Al Biruni was made court astrologer in Ghazni and he accompanied with Mahmud on his invasions on India. He lived for several years here and is considered to be first Indologist.
Babur first established himself in Kabul in 1504 A.D. and then pushed steadily southward into India from Afghanistanthrough the Khyber Pass. Later he successfully captured Bhira, Sialkot, and Lahore in Punjab.