The Great Wall of China was built over a period of centuries, beginning in the 7th century BC by the Qin Dynasty. It was expanded and strengthened by later dynasties, and the last parts of the wall were built in the 16th century during the Ming Dynasty.