 In 1865, at the age of 25, he traveled to the cities of Mecca and Medina.He stayed there for many years to acquire religious knowledge.He learnt Hadith from famous Sheikh Hasan Khizraji and Maulvi Rahmatullah Kiraynalwi.