Hinduism, chief religion of India, embracing many different sects and trends. In terms of numbers of adherents, it is the third largest of the world's religions, after Christianity and Islam. Hinduism is based on the Veda, sacred writings dating back some 3,000 years. The Veda comprised four types of writing: the Samhita, which in turn consists of 4 books of hymns, chants, and prayers—the Rig-Veda, the Sama-Veda, the Yajur-Veda, and the Atharva-Veda; the Brahmanas, which are prose; the Aranyakas, containing instructions for meditation; and the Upanishads, mystical works stating the Veda's doctrine of the soul.
Between 800 B.C. and 500 B.C. Hinduism began to change under the impact of two new, rival religions: Buddhism and Jainism. It absorbed many village and tribal gods into a pantheon dominated by Brahma (the creator), Vishnu (the preserver), and Shiva (the destroyer). In this period important social and philosophical changes occured: the caste system was established, and the learned Brahman, often a priest, became the supreme figure in society. The doctrine of reincarnation and the transmigration of the soul also became part of the creed. A further addition was the concept of karma, the idea that every individual is punished for wrongdoing and rewarded for righteousness, if not in the present life, then in a reincarnation. The aim of every Hindu should be to rise, through just living, higher and higher in the scale of existence with each reincarnation, finally attaining absorption into the personality of Brahma. Hinduism has various subcults, of which those of Shiva, Vishnu, Krishna, Shakti, and the Matris are the most important.