The Treaty of Nanking, signed in 1842, marked the end of the First Opium War between Great Britain and the Qing Dynasty. This "unequal treaty" ceded Hong Kong to Britain and opened several Chinese ports to trade, profoundly altering East Asian relations.