The Xiongnu () were nomads who lived north of China from about 3rd century BC to 460s AD. Their lands were very infertile, so they tried to attack China many times. As this was very irritating, the first emperor of China (Qin Shi Huang) built the Great Wall of China around 214 to 206 BC to keep them out. Some Han dynasty emperors tried to stop the wars and make friends with them, but they still tried to attack the Chinese borders.