The religion of ancient Persia and that of ancient India sprang from the same origin, namely, the ideas and usages which were shared alike by the Iranian and the Hindu branches of the original Aryan family. There are, indeed, traces of a civilization which existed in Persia prior to the Aryan invasion, and which closely resembled the Shamanism of the Accadians of ancient Chaldea. Little, however, is known of pre-Aryan Persia. All that can be said with certainty is that the Aryan invaders found already existing in Bactria and the neighboring regions a system of polytheism, which they replaced by a religion monotheistic in its tendency and similar in many respects to the religion of the Hindus of the Vedic period. The heaven god, known in India as Varuna, became the principal deity of the Iranians. Soma was also worshiped under the title Homa, and the distinction between Devas and Asuras ("shining ones" and "lords") was employed in Persia as well as in India to designate two important classes of divinities. Gradually, however, a change was introduced: a tendency towards dualism became more and more strongly marked; the Devas came to be recognized as evil deities, and the Ahuras (transliteration of Asuras) came to be looked upon as divinities friendly to man. "The conflict between these opposites assumed a moral form in the minds of the Iranian wanderers; the struggle between night and day, between the storm and the blue sky, of which the Vedic poets sang, was transformed into a struggle between good and evil. In place of the careless nature worshipers of the Panjab, a race of stern and earnest Puritans grew up among the deserts and rugged mountains of Ariana." 
This dualistic conception of the universe, this antithesis between good and evil, was already in possession when Zoroaster, or Zarathustra, the great religious reformer, appeared, about the middle of the seventh or the beginning of the sixth century B.C.  To him, according to Parsee tradition, is to be ascribed the inspired authorship of a portion, at least, of the Avesta, or sacred literature of the Persians. This collection consists of five Gathas, or hymns, written in an older dialect than that of the rest of the collection, the Vendidad, or compilation of religious laws and mythical tales, and the Zend, or commentary. The first two portions constitute the Avesta proper, that is to say, "law" or "knowledge." In addition to the Avesta-Zend, there existed the Khorda Avesta, or Small Avesta, which was a collection of prayers. Zoroaster's share in the composition of these books is a matter which it is impossible, in the present condition of our knowledge, to determine. It is, however, beyond dispute that the sacred literature of the Persians reflects the beliefs which existed before the time of Zoroaster as well as those which Zoroaster introduced. The religious reform effected by Zoroaster consisted in reducing to two more or less vague principles the good and evil elements in the universe. For him, as for his ancestors, the world is a vast battlefield, in which the forces of good and evil meet in a mighty conflict. But, instead of representing the contending forces as independent principles, manifold, yet capable of being classified as good and evil, he reduces all the conflicting powers to two, the good and the evil, of which the individual forces are derivatives. The good principle is called Ahura-mazda (Ormuzd, or Ormazd), and the evil principle is called Anra-mainyu (Ahrimân). The former is conceived as light and day, the latter as darkness and night. From the former proceed the Ahuras, or living lords (who were afterwards called Yazatas, or angels), and in general all that is good and beneficial to man: from the latter proceed the Devas, who opposed the Ahuras in the original conflict between day and night and who became the "demons" of latter Mazdeism, and, in general, from Ahrimân comes all that is evil and injurious to man.
 Sayce, The Ancient Empires of the East, p. 257.
 For the date of Zoroaster and the question of his historical reality, cf. Jackson, Zoroaster, the Prophet of Ancient Iran (London and New York, 1899), pp. 3 and 14, and Appendixes I and II.
It is man's duty to worship Ormazd (fire, being the sacred symbol, is also to be honored) by prayer, sacrifice, and the oblation of Homa (the juice of the sacred plant). It is also his duty to cultivate the soil and in other ways to promote the life and growth of the creatures of Ormazd, to destroy the works of Ahrimân, to kill all venomous and noxious things, and to rid the earth of all creatures injurious to man.
At the end of twelve thousand years the present cosmic period will come to an end. Ormazd will finally triumph, for, although Ahrimân is not inferior in power to Ormazd, he fights blindly and without adequate knowledge of the results of his actions; therefore, he and his works will come to an end, and, after the final struggle, storm and night will cease, calm and sunshine will reign, and all will be absorbed in Ormazd. In this universal absorption in Ormazd the human soul will be included.
Mazdeism (the religion of Ormazd) in its later development attached great importance to the worship of Mithra, the sun god. In this form it appeared in Rome and was among the first of the Oriental religions to gain ascendency over the minds of the Romans. Zoroastrianism was introduced as a heresy into the Christian Church by Manes, the founder of the Manichean sect.
Retrospect. In the systems of thought which flourished among the great historical nations of the East, there is, as has been observed, an almost complete lack of the rational element. In some of them, however, and especially in the Indian systems, there is abundance of speculation. Living in a country where there was practically no struggle for life, where the means of subsistence were produced without much effort on the part of the tillers of the soil, and where for thousands of years war was unknown save the war of extermination waged against the original dwellers in the land, the Hindus gave themselves up unreservedly to the solution of the problems, Whence are we come? Whereby do we live? and Whither do we go?
In solving these problems, however, the Hindus, while they succeeded better than other Oriental peoples in separating the speculative from the mythological, failed to develop the rational or dialectical phase of thought. Their speculative systems are positive rather than argumentative. It was in Greece that philosophy as a dialectical, argumentative science found its first home.
There can be no doubt that the systems which have just been sketched exercised some, if only an indefinite, influence on the speculative efforts of the first philosophers of Greece. The geographical contiguity and the commercial intercourse of the Hellenic colonies with the countries of the interior of Asia render such a supposition probable. It was not, however, until Greek philosophy had run its practically independent course of national development, that the religious systems of the Orient were finally united with the great current of Greek thought, East and the West pouring their distinctive contributions into the common stream of Greco-Oriental theosophy.
For bibliography, cf. De la Saussaye, Lehrbuch, II, 4, and Manual, p. 497. Consult Max Muller, The Six Systems of Indian Philosophy (London, 1899), and Deussen, Das System des Vedanta (1883), and Allg. Gesch. der Philosophie (1899).