The Chu–Han Contention (206–202 BC) was an interregnum between the Qin dynasty and the Han dynasty in Chinese history. Following the collapse of the Qin dynasty in 206 BC, Xiang Yu split the former Qin Empire into the Eighteen Kingdoms. Two major contending powers, Western Chu and Han, emerged from these kingdoms and engaged in a struggle for supremacy over China. Western Chu was led by Xiang Yu, while the Han leader was Liu Bang. During this period of time, some of the other kingdoms also fought battles against each other and/or against Han or Western Chu. These battles were largely independent of the main conflict between Western Chu and Han. The war ended in 202 BC with total victory for Han, after which China was unified under the Han dynasty with Liu Bang as the dynasty's first emperor.
In 221 BC, the Qin state unified China by conquering the other six major states and established the Qin dynasty. However, the dynasty lasted 16 years only because its rule was extremely unpopular due to its oppressive policies. In 209 BC, Chen Sheng and Wu Guang started the Dazexiang Uprising to overthrow the Qin dynasty. Although the uprising was crushed, several other rebellions erupted consecutively all around China over the next three years. Many rebel forces claimed to be restoring the former six states, and numerous pretenders to the thrones of the states emerged, resulting in the formation of many insurgent states. In 206 BCE, the last Qin emperor, Ziying, surrendered to Liu Bang and brought an end to the Qin dynasty.