The origin of Pahalgam is obscure. Mughal rulers ruled this region in the medieval period. It was later a part of the Kingdom of Kashmir, which was ruled by local Hindu rulers. This princely state remained independent even during the British period and later on merged into independent India