In 1805, the Nepalese general, Amar Singh Thapa, crossed the Yamuna at the invitation of Raja of Sirmur to suppress a rebellion of his subjects, but went on and laid siege to the Fort of Kangra. Sansar Chand resisted the Gurkhas for four long years. When he could fight no more, he solicited the help of Maharaja Ranjit Singh. The Maharaja marched an army to Kangra and defeated the Nepalese, but he seized the Fort, accepting Sansar Chand as a tributary of his government. Sansar Chand died in December 1823.
References :
1. Sun, Sohan Lal, `Umdat ut-Twarikh. Lahore, 1885-89
2. Griffin, Lepel, Ranjit Singh. Oxford, 1905
3. Hasrat, Bikrama Jit, Life and Times of Ranjit Singh. Nabha, 1977
4. Sinha, N.K., Ranjit Singh. Calcutta, 1908
5. Hutchinson J., and Ph. Vogel, History of the Punjab Hill States. Lahore, 1933