Lin Zexu
The Daoguang Emperor issued many imperial edicts banning opium in the 1820s and 1830s, which were carried out by Lin Zexu, whom he appointed as an Imperial Commissioner. Lin Zexu's efforts to halt the spread of opium in China led directly to the First Opium War. With the development of the First Opium War, Lin Zexu was made a scapegoat. The Daoguang Emperor removed his authority and banished him to Yili. Meanwhile, in the Himalayas, the Sikh Empire attempted an occupation of Tibet but was defeated in the Sino-Sikh war (1841–1842). On the coasts, the Qing Empire lost the war, exposing their technological and military inferiority to European powers, and ceded Hong Kong to the British in the Treaty of Nanjing in August 1842.