The earliest recorded event related to Sikkim is the passage of the Buddhist saint Guru Rinpoche through the land in the 8th century. The Guru is reported to have blessed the land, introduced Buddhism in Sikkim, and foretold the era of monarchy in the state that would arrive centuries later. In the 14th century, according to legend, Khye Bumsa, a prince from the Minyak House in Kham in Eastern Tibet, had a divine revelation one night instructing him to travel south to seek his fortunes. His descendants were later to form the royal family of Sikkim. In 1642, the fifth-generation descendant of Khye Bumsa, Phutsog Namgyal, was consecrated as the first Chogyal (king) of Sikkim by the three venerated Lamas who came from the north, west and south to Yuksom, marking the beginning of the monarchy.
Phuntsog Namgyal was succeeded in 1670 by his son, Tensung Namgyal, who moved the capital from Yuksom to Rabdentse. In 1700, Sikkim was invaded by the Bhutanese with the help of the half-sister of the Chogyal, who had been denied the throne. The Bhutanese were driven away by the Tibetans, who restored the throne to the Chogyal ten years later. Between 1717 and 1733, the kingdom faced many raids by the Nepalese in the west and Bhutanese in the east, culminating with the destruction of the capital Rabdentse by the Nepalese. In 1791, China sent troops to support Sikkim and defend Tibet against the Gurkhas. Following Nepal's subsequent defeat, the Qing Dynasty established control over Sikkim. Following the arrival of the British Raj in neighbouring India, Sikkim allied with them against their common enemy, Nepal. The Nepalese attacked Sikkim, overrunning most of the region including the Terai. This prompted the British East India Company to attack Nepal, resulting in the Gurkha War of 1814. Treaties signed between Sikkim and Nepal — the Sugauli Treaty — and Sikkim and British India — the Titalia Treaty — returned the territory annexed by the Nepalese to Sikkim in 1817. Ties between Sikkim and the British administrators of India grew sour, however, with the beginning of British taxation of the Morang region. In 1849 two British doctors, Sir Joseph Dalton Hooker and Dr Archibald Campbell, the latter being in charge of relations between the British and Sikkim Government, ventured into the mountains of Sikkim unannounced and unauthorised. The doctors were detained by the Sikkim government, leading to a punitive British expedition against the Himalayan kingdom, after which the Darjeeling district and Morang were annexed to India in 1853. The invasion led to the Chogyal becoming a puppet king under the directive of the British governor.
In 1947, a popular vote rejected Sikkim's joining the Indian Union and Prime Minister Jawaharlal Nehra agreed to a special protectorate status for Sikkim. Sikkim came under the suzerainty of India, which controlled its external affairs, defence, diplomacy and communications, but Sikkim otherwise retained autonomy. A state council was established in 1955 to allow for constitutional government under the Chogyal. Meanwhile trouble was brewing in the state after the Sikkim National Congress demanded fresh elections and greater representation for the Nepalese. In 1973, riots in front of the palace led to a formal request for protection from India. The Chogyal was proving to be extremely unpopular with the people. In 1975, the Kazi (Prime Minister) appealed to the Indian Parliament for a change in Sikkim's status so that it could become a state of India. In April, the Indian Army moved into Sikkim, seizing the city of Gangtok and disarming the Palace Guards. A referendum was held in which 97.5% of the voting people (59% of the people entitled to vote) voted to join the Indian Union. A few weeks later, on May 16, 1975, Sikkim officially became the 22nd state of the Indian Union and the monarchy was abolished.
In 2000, the seventeenth Karmapa Urgyen Trinley Dorje, who had been proclaimed a Lama by China, made a dramatic escape from Tibet to the Rumtek Monastry in Sikkim. Chinese officials were in a quandary on this issue, as any protests to India would mean an explicit endorsement of India's governance of Sikkim, which the Chinese still regarded as an independent state occupied by India. China eventually recognized Sikkim as an Indian state in 2003, on the condition that India accepted Tibet Autonomous Region as a part of China. This mutual agreement led to a thaw in Sino-Indian relations. New Delhi accepted Tibet as a part of China in 1953 during the government of then Prime Minister Jawaharlal Nehru. On July 6, 2006 the Himalayan pass of Nathula was opened to cross-border trade, further evidence of improving relations in the region.[