The Opium Wars were two wars in the mid-19th century involving Great Qing and the British Government and concerned their imposition of trade of opium upon China, thus compromising China’s territorial sovereignty and economic power for almost a century. The clashes included the First Opium War (1839–1842), with the British naval forces, and in the Second Opium War (1856–1860), also known as the Arrow or Anglo-French Wars to the Chinese, Britain was aided by French forces. The wars and subsequently imposed treaties weakened the Qing dynasty and Chinese governments, and forced China to increase its imports from colonial and imperial powers.
In 1820, before the first Opium War, China's economy was the largest in the world, according to British economist Angus Maddison. In another investigative report published by Michael Cemblast of JP Morgan and updated by the World Economic Forum, similar conclusions were reached—i.e., China's economy was the largest in the world for many centuries until the Opium Wars. Furthermore, China was a net exporter, and had large trade surpluses with most Western countries. Within a decade after the end, and as a result of the Second Opium War, China's share of global GDP had fallen by half, and its sovereignty over its territory was seriously compromised until the end of World War II, and the retrocession of Hong Kong and Macao at the end of the 20th century. 
First Opium War
In the late 18th century, the British East India Company or EIC, contravening Chinese laws, began smuggling Indian opium to China through various means, and became the leading suppliers by 1773. By 1787, the Company was illegally sending 4,000 chests of opium to China a year, each chest weighing 170 lbs or 77 kilos. By 1828, opium accounted for 16% of the EIC's total revenue, while 10% of British government taxes came from the tea imported as a result. The EIC paid its opium agents £7,500 per year, a salary higher than that received by the Chancellor of the Exchequer and the trade drove the expansion of British India. One factor in the annexation of Sindh in 1843 was to protect the EIC monopoly, which was threatened by the export of opium from Karachi aboard Portuguese trading vessels.
The Chinese Emperor passed many decrees/edicts making opium trade illegal in 1729, 1799, 1814 and 1831, but smuggling still occurred as the British paid smugglers to take opium into China, causing the population to become more and more addicted. This in turn let tons of opium into China's markets  Some Americans entered the trade by smuggling opium from Turkey into China. Some of the individual American opium smugglers included the grandfather of US President Franklin D. Roosevelt and ancestors of the former US Secretary of State John Forbes Kerry. By 1833, the number of chests of opium trafficked into China soared to 30,000. According to United Nations Office on Drugs and Crime, the East India Company sent the opium to their warehouses in the free trade region of Canton (Guangzhou), from where Chinese smugglers would take the opium farther into China. The British Empire sponsored opium traffic resulted in 10–12 million Chinese addicts and devastated especially the large coastal Chinese cities. In 1834, the East India Company monopoly ceased. The illegal trade, however, continued. In 1839, after having the Lin Tse-hsu Letter to the British monarch Queen Victoria pleading for a halt to the opium contraband ignored, the Emperor issued an edict ordering the seizure of all the opium in Canton, including that held by foreign governments and placed matters in the hands of a High Commissioner, Lin Tse-hsu. The smugglers lost 20,000 chests (1,300 metric tons) of opium without being legally entitled to compensation.
China initially attempted to get foreign companies to forfeit their opium stores in exchange for tea, but this ultimately failed too. Then China resorted to using force in the western merchants' enclave. Forces confiscated all supplies and ordered a blockade of foreign ships to get them to surrender their illegal opium supply.
The British trade commissioner in Canton, Captain Charles Elliot, wrote to London advising the use of military force against the Chinese. Almost a year passed before the British government decided, in May 1840, to send troops to impose reparations for the economic losses of the British illegal traders in Canton including financial compensation, and to guarantee future security for smugglers. However the first hostilities had occurred some months earlier with a skirmish between British and Chinese vessels in the Kowloon Estuary on 4 September 1839. On 21 June 1840 a British naval force arrived off Macao then moving to bombard the port of Ting-ha. In the ensuing conflict, the Royal Navy used its naval and gunnery power to inflict a series of decisive defeats on the Chinese Empire, a tactic later referred to as gunboat diplomacy.
The war was concluded by the Treaty of Nanking (Nanjing) in 1842, the first of the treaties between China and foreign and illegal drug trading imperialist powers.  The treaty forced China to cede the Hong Kong island with surrounding smaller islands, to the United Kingdom in perpetuity, and it established five treaty ports at Shanghai, Canton, Ningpo (Ningbo), Foochow (Fuzhou), and Amoy (Xiamen). The treaty also demanded a twenty-one million dollar payment to Great Britain, with six million paid immediately and the rest through specified installments thereafter. Another treaty the next year gave most favored nation status to the British Empire and added provisions for British extraterritoriality. France secured concessions on the same terms as the British, in treaties of 1843 and 1844.
Second Opium War
In 1853 civil war broke out in China with a rival Emperor establishing himself at Nanking. Notwithstanding this, a new Imperial Commissioner, Yeh Ming-ch'en was appointed at Canton, the principal trading port of foreigners, whom he loathed; he was determined to stamp out the illegal opium trade. In October 1856 he seized the British ship Arrow and threw its crew into chains. Sir John Bowring, Governor of Hong Kong, called up Admiral Sir Michael Seymour's fleet which, on 23 October, bombarded and captured the forts which guarded the approach to Canton on the Pearl River, and then proceeded to bombard Canton itself but had insufficient forces to take and hold the city. On 15 December, during a riot in Canton, European commercial properties were set on fire and Bowring appealed for military intervention. Following the gruesome murder of a French missionary, Britain now had French support. Britain now sought greater concessions from China, including legalization of the opium trade, to expand trade in coolies (cheap laborers), to open all of China to British merchants and opium traffickers, and to exempt foreign imports from internal transit duties. The war resulted in the Treaty of Tientsin (26 June 1858), which imposed on the Chinese the obligation to pay reparations for the expenses of the recent war, a second group of ten more ports being opened to European commerce, the legalisation of the opium trade, and foreign traders and missionaries gained rights to travel within China.
- Taylor Wallbank; Bailkey; Jewsbury; Lewis; Hackett (1992). "A Short History of the Opium Wars (from: Civilizations Past And Present, Chapter 29: South And East Asia, 1815–1914)".<templatestyles src="Module:Citation/CS1/styles.css"></templatestyles>
- Kenneth Pletcher. "Chinese history: Opium Wars". Encyclopædia Britannica Online.<templatestyles src="Module:Citation/CS1/styles.css"></templatestyles>
- Thompson, Peter. "Karl Marx, part 4: 'Workers of the world, unite". The Guardian. Retrieved 22 March 2019.<templatestyles src="Module:Citation/CS1/styles.css"></templatestyles>
- Farooqui, Amar (2005). Smuggling as Subversion: Colonialism, Indian Merchants, and the Politics of Opium, 1790-1843. Lanham, Md.: Lexington Books. ISBN 978-0739108864. OCLC 57286105.<templatestyles src="Module:Citation/CS1/styles.css"></templatestyles>
- Teng, Ssu-Yu; Collis, Maurice; Pelcovits, Nathan A. (August 1948). "Foreign Mud; Being an Account of the Opium Imbroglio at Canton in the 1830's and the Anglo-Chinese war that Followed". The Far Eastern Quarterly. 7 (4): 435. doi:10.2307/2049731. ISSN 0363-6917. JSTOR 2049731.<templatestyles src="Module:Citation/CS1/styles.css"></templatestyles>
- Treaty of Nanking - Nanking, August 29, 1842 - Peace Treaty between the Queen of the United Kingdom of Great Britain and Ireland and the Emperor of China - Ratifications exchanged at Hongkong, 26th June 1843.<templatestyles src="Module:Citation/CS1/styles.css"></templatestyles>
- "Opium trade - History & Facts". Encyclopedia Britannica. Retrieved 3 July 2018.<templatestyles src="Module:Citation/CS1/styles.css"></templatestyles>
- Hanes III, William Travis; Sanello, Frank (2004). The Opium Wars: The Addiction of One Empire and the Corruption of Another. United States: Sourcebooks. pp. 21, 24, 25. ISBN 978-1402201493.<templatestyles src="Module:Citation/CS1/styles.css"></templatestyles>
- Murray, Craig (2016). Sikunder Burnes: Master of the Great Game. Birlinn Ltd. p. 39. ISBN 978-1780273174.<templatestyles src="Module:Citation/CS1/styles.css"></templatestyles>
- "A Century of International Drug Control" (PDF). UNODC.org.<templatestyles src="Module:Citation/CS1/styles.css"></templatestyles>
- Meyer, Karl E. "The Opium War's Secret History". Retrieved 3 July 2018.<templatestyles src="Module:Citation/CS1/styles.css"></templatestyles>
- Haythornthwaite, Philip J., The Colonial Wars Source Book, London, 2000, p.237. ISBN 1-84067-231-5
- Haythornthwaite, 2000, p.237.
- Haythornthwaite, 2000, p.237.
- Tsang, Steve (2007). A Modern History of Hong Kong. I.B.Tauris. pp. 3–13, 29. ISBN 1-84511-419-1.
- Haythornthwaite, 2000, p.239.
- Xiaobing Li (2012). China at War: An Encyclopedia. ABC-CLIO. p. 468.<templatestyles src="Module:Citation/CS1/styles.css"></templatestyles>
- Haythornthwaite, 2000, p.239.
- Zhihong Shi (2016). Central Government Silver Treasury: Revenue, Expenditure and Inventory Statistics, ca. 1667-1899. BRILL. p. 33. ISBN 978-90-04-30733-9.<templatestyles src="Module:Citation/CS1/styles.css"></templatestyles>
- Haythornthwaite, 2000, p.239.
- Beeching, Jack. The Chinese Opium Wars (Harvest Books, 1975)
- Fay, Peter Ward. The Opium War, 1840-1842: barbarians in the Celestial Empire in the early part of the nineteenth century and the war by which they forced her gates ajar (Univ of North Carolina Press, 1975).
- Gelber, Harry G. Opium, Soldiers and Evangelicals: Britain's 1840-42 War with China, and Its Aftermath. Palgrave Macmillan, 2004).
- Hanes, W. Travis and Frank Sanello. The Opium Wars: The Addiction of One Empire and the Corruption of Another (2014) excerpt
- Kitson, Peter J. "The Last War of the Romantics: De Quincey, Macaulay, the First Chinese Opium War" Wordsworth Circle (2018) 49#3 online
- Lovell, Julia. The Opium War: Drugs, Dreams, and the Making of Modern China (2011). excerpt
- Platt, Stephen R. Imperial Twilight: The Opium War and the End of China's Last Golden Age (NY Vintage, 2018), 556 pp. excerpt
- Polachek, James M., The inner opium war (Harvard Univ Asia Center, 1992).
- Waley, Arthur, ed. The Opium War through Chinese eyes (1960).
- Wong, John Y. Deadly Dreams: Opium, Imperialism, and the Arrow War (1856-1860) in China. (Cambridge UP, 2002) excerpt
- Yu, Miles Maochun. "Did China Have A Chance To Win The Opium War?" Military History in the News July 3, 2018