The ultimate canonical authority for all Hindus is the Vedas. The oldest of the four Vedas is the Rig-Veda, which was composed in an ancient form of the Sanskrit language in northwest India. This text, probably composed between about 1500 and 1000 BC and consisting of 1028 hymns to a pantheon of gods, has been memorized syllable by syllable and preserved orally to the present day. The Rig-Veda was supplemented by two other Vedas, the Yajur-Veda (the textbook for sacrifice) and the Sama-Veda (the hymnal). A fourth book, the Atharva-Veda (a collection of magic spells), was probably added about 900 BC. At this time, too, the Brahmanas—lengthy Sanskrit texts expounding priestly ritual and the myths behind it—were composed. Between the 8th century BC and the 5th century BC, the Upanishads were composed; these are mystical-philosophical meditations on the meaning of existence and the nature of the universe.
The Vedas, including the Brahmanas and the Upanishads, are regarded as revealed canon (shruti,”what has been heard [from the gods]”), and no syllable can be changed. The actual content of this canon, however, is unknown to most Hindus. The practical compendium of Hinduism is contained in the Smriti, or “what is remembered,” which is also orally preserved. No prohibition is made against improvising variations on, rewording, or challenging the Smriti. The Smriti includes the two great Sanskrit epics, the Mahabharata and the Ramayana; the many Sanskrit Puranas, including 18 great Puranas and several dozen more subordinate Puranas; and the many Dharmashastras and Dharmasutras (textbooks on sacred law), of which the one attributed to the sage Manu is the most frequently cited.
The two epics are built around central narratives. The Mahabharata tells of the war between the Pandava brothers, led by their cousin Krishna, and their cousins the Kauravas. The Ramayana tells of the journey of Rama to recover his wife Sita after she is stolen by the demon Ravana. But these stories are embedded in a rich corpus of other tales and discourses on philosophy, law, geography, political science, and astronomy, so that the Mahabharata (about 200,000 lines long) constitutes a kind of encyclopedia or even a literature, and the Ramayana (more than 50,000 lines long) is comparable. Although it is therefore impossible to fix their dates, the main bodies of the Mahabharata and the Ramayana were probably composed between 400 BC and AD 400. Both, however, continued to grow even after they were translated into the vernacular languages of India (such as Tamil and Hindi) in the succeeding centuries.
The Puranas were composed after the epics, and several of them develop themes found in the epics (for instance, the Bhagavata-Purana describes the childhood of Krishna, a topic not elaborated in the Mahabharata). The Puranas also include subsidiary myths, hymns of praise, philosophies, iconography, and rituals. Most of the Puranas are predominantly sectarian in nature; the great Puranas (and some subordinate Puranas) are dedicated to the worship of Shiva or Vishnu or the Goddess, and several subordinate Puranas are devoted to Ganesha or Skanda or the sun. In addition, they all contain a great deal of nonsectarian material, probably of earlier origin, such as the “five marks,” or topics (panchalakshana), of the Puranas: the creation of the universe, the destruction and re-creation of the universe, the dynasties of the solar and lunar gods, the genealogy of the gods and holy sages, and the ages of the founding fathers of humankind (the Manus).