The Buddhist monk Xuanzang (玄奘， 602–664 ) became famous for his seventeen-year overland journey to India, which is recorded in detail in the classic Chinese text Great Tang Records on the Western Regions, which in turn provided the inspiration for the novel Journey to the West written by Wu Cheng’en during the Ming dynasty, around nine centuries after his death.
Xuanzang was fully ordained as a monk in 622, at the age of twenty. The myriad contradictions and discrepancies in the texts at that time prompted Xuanzang to decide to go to India and study in the cradle of Buddhism.
In 629, Xuanzang reportedly had a dream that convinced him to journey to India. Tang China and the Göktürks were at war at the time and Emperor Taizong of Tang had prohibited foreign travel. Xuanzang persuaded some Buddhist guards at Yumen Pass and slipped out of the empire through Liangzhou (Gansu) and Qinghai in 629. He subsequently travelled across the Gobi Desert to Kumul (modern Hami City), thence following the Tian Shan westward.
He arrived in Turpan in 630. Here he met the king of Turpan, a Buddhist who equipped him further for his travels with letters of introduction and valuables to serve as funds. The hottest mountain in China, the Flaming Mountains, is located in Turpan and was depicted in the Journey to the West.
Moving further westward, Xuanzang escaped robbers to reach Karasahr, then toured the non-Mahayana monasteries of Kucha. Further west he passed Aksu before turning northwest to cross the Tian Shan’s Bedel Pass into modern Kyrgyzstan. He skirted Issyk Kul before visiting Tokmak on its northwest, and met the great Khan of the Göktürks, whose relationship to the Tang emperor was friendly at the time. After a feast, Xuanzang continued west then southwest to Tashkent, capital of modern Uzbekistan. From here, he crossed the desert further west to Samarkand. In Samarkand, which was under Persian influence, the party came across some abandoned Buddhist temples and Xuanzang impressed the local king with his preaching. Setting out again to the south, Xuanzang crossed a spur of the Pamirs and passed through the famous Iron Gates. Continuing southward, he reached the Amu Darya and Termez, where he encountered a community of more than a thousand Buddhist monks.
Further east he passed through Kunduz, where he stayed for some time to witness the funeral rites of Prince Tardu, who had been poisoned. Here he met the monk Dharmasimha, and on the advice of the late Tardu made the trip westward to Balkh (modern Afghanistan), to see the Buddhist sites and relics, especially the Nava Vihara, which he described as the westernmost vihara in the world. Here Xuanzang also found over 3,000 non-Mahayana monks, including Prajnakara (般若羯羅 or 慧性), a monk with whom Xuanzang studied early Buddhist scriptures. He acquired the important text of the Mahāvibhāṣa (Chinese: 大毗婆沙論) here, which he later translated into Chinese.
Prajñakara then accompanied the party southward to Bamyan, where Xuanzang met the king and saw tens of non-Mahayana monasteries, in addition to the two large Buddhas of Bamiyan carved out of the rockface. The party then resumed their travel eastward, crossing the Shibar Pass and descending to the regional capital of Kapisi (about 60 kilometres (37 mi) north of modern Kabul), which sported over 100 monasteries and 6000 monks, mostly Mahayana. This was part of the fabled old land of Gandhara. Xuanzang took part in a religious debate here, and demonstrated his knowledge of many Buddhist schools. Here he also met the first Jains and Hindu of his journey. He pushed on to Adinapur (later named Jalalabad) and Laghman, where he considered himself to have reached India. The year was 630.