The region around Chennai has served as an important administrative, military, and economic centre since the 1st century. Stone age implements were found in a pit near Pallavaram in Chennai. According to the archeological survey of India, Pallavaram was a megalithic cultural establishment.
The area was ruled by various South Indian dynasties, notably the Pallava, the Chera Dynasty, the Chola, the Pandya, and Vijaynagar. The town of Mylapore, now part of Chennai, was once a major Pallavan port. The Portuguese arrived in 1522 and built a port called São Tomé after the Christian apostle, St Thomas, who is believed to have preached in the area between 52 and 70 AD. In 1612, the Dutch established themselves near Pulicat, just north of the city.
On 22 August 1639, Francis Day of the British East India Company bought a small strip of land on the Coromandel Coast. The region was ruled by Damarla Venkatadri Nayakudu,, the Nayaka of Vandavasi. He granted the British permission to build a factory and warehouse for their trading enterprises. A year later, the British built Fort St George, which became the nucleus of the growing colonial city. Fort St. George housed the Tamil Nadu Assembly until the new Secretariat building was opened in 2010. In 1746, Fort St. George and Madras were captured by the French under General La Bourdonnais, the Governor of Mauritius, who plundered the town and its outlying villages. The British regained control in 1749 through the Treaty of Aix-la-Chapelle and fortified the town's fortress wall to withstand further attacks from the French and another looming threat, Hyder Ali, the Sultan of Mysore. By the late 18th century, the British had conquered most of the region around Tamil Nadu and the northern modern-day states of Andhra Pradesh and Karnataka, establishing the Madras Presidency with Madras as the capital. Under British rule, the city grew into a major urban centre and naval base.
With the advent of railways in India in the late 19th century, the thriving urban centre was connected to other important cities such as Bombay and Calcutta, promoting increased communication and trade with the hinterland.
Madras was the only Indian city to be attacked by the Central Powers during World War I, when an oil depot was shelled by the German light cruiser SMS Emden on 22 September 1914, as it raided shipping lanes in the Indian Ocean, causing disruption to shipping.
After India gained its independence in 1947, the city became the capital of Madras State, renamed the state of Tamil Nadu in 1969. The violent agitations of 1965 against the imposition of Hindi as the national language, marked a major shift in the political dynamics of the city and the whole state.
On 26 December 2004, an Indian Ocean tsunami lashed the shores of Chennai, killing many and permanently altering the coastline.