testimony of inscriptions (the earliest dating back to the 4th century AD), literary accounts, and local traditions it may be suggested that Far-Western Region of Nepal and Uttarakhand formed one single polity for centuries under the Katyuri kings. Therefore, both regions inherit a shared past or collective memory. In the Bharat/Jagar of Maula, Jiyarani, a Katyuri princess, as narrated in Doti (modern-day Nepal) and Uttarakhand (present-day India) is an example of this common heritage. In the book of Rahul Sankrityayan, Himalaya Parichaya: Garwahl (Allahabad 1953) it is written that, "The kings of Kumaon-Garhwal were called, Kedare Khasamandale which means Kedar region as the residence of Khas people". The royal dynasty of Garhwal started with Kanak Pal. Garhwal Kingdom was founded in 823 AD, when Kanak Pal, the prince of Malwa (present day Madhya Pradesh), on his visit to the Badrinath Temple, met Raja Bhanu Pratap, the ruler of Chandpur Garhi, one of the 52 Garhs of Garhwal. Raja Bhanu Pratap had no sons. The King married his only daughter to the prince and subsequently handed over his kingdom, the fortress town. Kanak Pal and his descendants of Panwar dynasty, gradually conquered all the independent fortresses (Garhs) belonging to its 52 small chieftains, and ruled the whole of Garhwal Kingdom for the next 916 years, up to 1804 AD. Medieval In 1358, the 37th ruler, Ajay Pal, brought all the minor principalities for the Garhwal region, under his own rule, and founded the Garhwal Kingdom, with Devalgarh as its capital, which he later shifted to Srinagar. Balbhadra Shah (r. 1575–1591), was the first Raja of Garhwal to use the title Shah. The capital was shifted to Srinagar by Mahipat Shah who ascended to the throne in 1622, and further consolidated his rule over most parts of Garhwal, though he died early in 1631, though his seven-year-old son, Prithvi Shah ascended to the throne after him, the Kingdom was ruled by Mahipat Shah's wife, Rani Karnavati for many years to come, during which she successfully defended the kingdom against invaders and repelled an attack of Mughal army led by Najabat Khan in 1640, and in time received the nickname of 'Nakti Rani' as she used to chop off the noses of any invader to the kingdom, as the Mughal invaders of the period realised. Monuments erected by her still exist in Dehradun district at Nawada. The next important ruler was Fateh Shah,