India's first major civilisation flourished for a thousand years from around 2500 BC along the Indus River valley. Its great cities were Mohenjodaro and Harappa (in what is now Pakistan), which were ruled by priests and held the rudiments of Hinduism. Aryan invaders swept south from Central Asia between 1500 and 200 BC and controlled northern India, pushing the original Dravidian inhabitants south.
The invaders brought their own gods and cattle-raising and meat-eating traditions, but were absorbed to such a degree that by the 8th century BC the priestly caste had reasserted its supremacy. This became consolidated in the caste system, a hierarchy maintained by strict rules that secured the position of the Brahmin priests. Buddhism arose around 500 BC, condemning caste; it drove a radical swathe through Hinduism in the 3rd century BC when it was embraced by the Mauryan Emperor Ashoka, who controlled huge tracts of India.
A number of empires, including the Guptas, rose and fell in the north after the collapse of the Mauryas. Hinduism underwent a revival from 40 to 600 AD, and Buddhism began to decline. The north of India broke into a number of separate Hindu kingdoms after the Huns' invasion; it was not really unified again until the coming of the Muslims in the 10th and 11th centuries. The far south, whose prosperity was based on trading links with the Egyptians, Romans and southeast Asia, was unaffected by the turmoil in the north, and Hinduism's hold on the region was never threatened.
In 1192 the Muslim Ghurs arrived from Afghanistan. Within 20 years the entire Ganges basin was under Muslim control, though Islam failed to penetrate the south. Two great kingdoms developed in what is now Karnataka: the mighty Hindu kingdom of Vijayanagar, and the fragmented Bahmani Muslim kingdom.
Mughal emperors marched into the Punjab from Afghanistan, defeated the Sultan of Delhi in 1525, and ushered in another artistic golden age. The Maratha Empire grew during the 17th century and gradually took over more of the Mughals' domain. The Marathas consolidated control of central India until they fell to the last great imperial power, the British.
The British were not, however, the only European power in India: the Portuguese had controlled Goa since 1510 and the French, Danes and Dutch also had trading posts. By 1803, when the British overwhelmed the Marathas, most of the country was under the control of the British East India Company, which had established its trading post at Surat in Gujarat in 1612.
Opposition to British rule began in earnest at the turn of the 20th century. The 'Congress' which had been established to give India a degree of self-rule, now began to push for the real thing. In 1915, Gandhi returned from South Africa, where he had practised as a lawyer, and turned his abilities to independence, adopting a policy of passive resistance, or satyagraha.
Faced with a political stand-off and rising tension, Viceroy Mountbatten reluctantly decided to divide the country and set a rapid timetable for independence. Unfortunately, the two overwhelmingly Muslim regions were on opposite sides of the country - meaning the new nation of Pakistan would be divided by a hostile India. When the dividing line was announced, the greatest exodus in human history took place as Muslims moved to Pakistan and Hindus and Sikhs relocated to India. Over 10 million people changed sides and even the most conservative estimates calculate that 250,000 people were killed. On 30 January 1948, Gandhi, deeply disheartened by Partition and the subsequent bloodshed, was assassinated by a Hindu fanatic.