The pineal gland (also called the pineal body, epiphysis cerebri, epiphysis or the “third eye”) is an endocrine gland found in vertebrates that is the source of melatonin, a hormone derived from tryptophan that plays a central role in the regulation of circadian rhythm (the roughly 24-hour cycle of biological activities associated with natural periods of light and darkness).
The shape of the gland resembles a pine cone, and gives it its name. The pineal gland is located in the epithalamus, near the center of the brain, between the two hemispheres, tucked in a groove where the two halves of the thalamus join. The pineal gland is one of the neuroendocrine secretory circumventricular organs in which capillaries are mostly permeable to solutes in the blood. 
Nearly all vertebrate species possess a pineal gland. The most important exception is a primitive vertebrate, the hagfish. Even in the hagfish, however, there may be a “pineal equivalent” structure in the dorsal diencephalon. The lancelet Branchiostoma lanceolatum, the nearest existing relative to vertebrates, also lacks a recognizable pineal gland. The lamprey (another primitive vertebrate), however, does possess one. A few more developed vertebrates have lost pineal glands over the course of their evolution.
The results of various scientific research in evolutionary biology, comparative neuroanatomy and neurophysiology have explained the evolutionary history (phylogeny) of the pineal gland in different vertebrate species. From the point of view of biological evolution, the pineal gland represents a kind of atrophied photoreceptor. In the epithalamus of some species of amphibians and reptiles, it is linked to a light-sensing organ, known as the parietal eye, which is also called the pineal eye or third eye.
In occultism the pineal gland is regarded as a link between the objective and subjective states of consciousness; or, in exoteric terminology, the visible and invisible worlds of Nature. In the religions of the Latins it was, therefore, referred to as Janus, the two-faced god and keeper of the gates of sanctuary. This divinity was the antitype of St. Peter, who succeeded him as the warder of the heavenly portals and who carries the two keys of his office—one to the golden mystery of the spirit and the other to the silver mystery of the body. Two-faced gods are frequently spoken of in ancient records. Hermae like the bifrons Janus may still be seen in old Roman villas, with the occasional and intriguing exception that one of the faces will be male and the other female—the herm- aphroditus again? The female face represents the animal soul and the male the divine soul, and the whole figure is indicative of the occult structure and function of the pineal gland. Gould, in his Mythical Monsters, gives several examples drawn from the earliest writings of the Chinese. Hindu mythology also abounds in polycephalous divinities, and from the far-off Tibetans we learn that one of the titles of Avalokiteshvara is Samanta-mukha, “he whose face looks every way.” There is an alchemical mystery also in connection with the pineal gland, for the regeneration of man is dependent upon the tincturing of this gland, which must be transmuted from base metal into gold. Unawakened by Kundalini, the pineal gland is the vehicle of kama-manas—the animal mind (Aphrodite) —but when tinctured by the spiritual light, it becomes buddhimanas—the divine mind (Hermes). This buddhi-manas is the Thoth of the later Egyptian Mysteries, the god of learning and letters, and (according to the extravagant statements of his priests) the source of twenty-six thousand books. 
The philosophers know that the pineal gland was an organ of conscious vision long before the physical eyes issued from the brain, not necessarily or exclusively of such vision as we have today but rather vision of that world wherein man dwelt before his lapse into his present state. As his contact with the physical world grew more complete, the individual lost his functions upon the inner planes of life, together with his conscious connection with the Creative Hierarchies in the universe about him. Only through discipline—effort directed by wisdom and law—can he rise again into the sphere of his spiritual completeness. It is a mistake to infer that the pineal gland as a physical body literally possesses all the occult virtues ascribed to it by the sages. The gland itself is not the third eye, but only the reflection of that organ—its counterpart or symbol in the material constitution. It is a relic bearing witness to an ancient faculty, and because it has endured through these eras of spiritual obscuration, promises the ultimate restoration of the function to which it bears witness. The true power of the gland is in its spiritual counter-part, even as the whole strength of man abides in his invisible nature. The true third eye cannot be seen by the ordinary vision, but is visible to the clairvoyant as a vibrant spectromatic aura surrounding the outer body of the gland and pulsating with an electrical light. “,” H. P. Blavatsky writes:
“The special physical organ of perception in the brain is located in the aura of the pineal gland. This aura answers in vibration to any impression, but it can only be sensed, not perceived, in the living man. During the process of thought, manifesting in consciousness, a constant vibration occurs in the light of this aura, and a clairvoyant looking at the brain of a living man may almost count, see with the spiritual eye, the seven scales, the seven shades of light, passing from the dullest to the brightest. You touch your hand; before you touch it the vibration is already in the aura of the pineal gland, and has its own shade of color. It is this aura which causes the wear and tear of the organ, by the vibrations it sets up. The brain set vibrating conveys the vibrations to the spinal cord and so to the rest of the body. Powerful vibrations of joy or sorrow may thus kill. The fires are always playing around the pineal gland but when the Kundalini illuminates them for a brief instant the whole universe is seen. Even in deep sleep the third eye opens. This is good for Manas, who profits by it, though we ourselves do not remember.”
It was Rene Descartes who saw the pineal gland as the abode of the soul or the sidereal spirit in man.  He reasoned that although the anima was joined to every organ of the body, there must be one special part through which the divine portion exercised its functions more directly than through the rest. After concluding that neither the heart nor the brain could be as a whole that special locality, he decided through a process of elimination that it must be that little gland which, though bound to the brain, yet had an action or motion independent of it. Descartes concluded that the pineal gland could be put into a kind of swinging motion by the animal spirits which move through the concavities of the skull. We must consider him, therefore, as a powerful figure in the transition period between mediaeval and modern science. 
In ascribing motion to the pineal gland, Descartes, though not an occultist, hit upon one of the most profound secrets of the ancient Mysteries. The great Descartes continues:
“Accordingly the Common Sense may be described to be an Internal Sense, whereby all the Objects of the External Senses are perceived and united in the midst of the Brain, as the common Center of all Impressions. Or the Common Sense is nothing else, but the concurrence of all motions made by the Objects upon the Nerves, in the Conarion, happening at the same time that the Objects move the Senses. Neither doth the Smallness of this Kernel hinder its being the Instrument of the Common Sense; but on the contrary, those Persons are the most stupid in whom this Kernel, because of its bigness, is not so easily moved; and those the most witty and apprehensive in whom this Kernel is less, because it is so much the more easily moved: And tho’ it were much less than it is, yet would it be big enough with respect to the several Points of the Ventricles, and to the Pipes of the Nerves.” For centuries Descartes was ridiculed by the learned, and his mystical conclusions were of that type relegated by the great Tyndall to the field of “poesy.” And now at this late day comes a “conditional” vindication of Descartes’ views from a science which, all too often, suffers from an “infallibility” complex. “Recently, however, the great Frenchman’s idea is gaining favor in the eye of science—that is, if we regard the soul as a department of the human intellect. [Sic!] For, apparently, the pineal gland is concerned directly, although still mysteriously, with the development of intelligence.”
The “All-Seeing Eye” of the Masonic Brethren; the “Eye Single” of the Scriptures by which the body is filled with light; the “One Eye” of Odin which enabled him to know all the Mysteries; the “Eye of Horus” which at one time Typhon swallows up; the “Eye of the Lord” which, as Boehme says, “beholds all”—all these, then, are but allusions to that primitive organ which, according to the commentaries forming the basis of The Secret Doctrine “getting gradually petrified,” disappeared from view, having been drawn “deeply into the head” and buried “deeply under the hair.” It is of this, then, that Proclus writes in his first book On the Theology of Plato, where he declares that the soul, having entered into the adytum, or inner recesses of her nature, perceives “the genus of the gods, and the unities of things” without the aid of her objective eyes, which arc described as “closed.” Is there anything unscientific, then, in affirming that the pineal gland is the third eye of the historico-mythological “men of ancient times,” such as are recorded by Berossus in his fragments on the origins of the Chaldeans and of which the Greeks have record in their fables of the Cyclops ? The mystic knows that the pineal gland is all that remains of the “Eye of Dangma,” the inner eye of the illumined sage, the “Eye of Shiva” placed vertically upon the foreheads of the gods and Dhyanas to signify that in them the spiritual sight is not obscured. When gazing at the inscrutable face of Avalokiteshvara, be reminded by his third eye of the commentaries wherein it is written that when the inner “man” is active, the eye “swells and expands,” and the Arhat is able to feel and see this activity and regulate his actions accordingly.
Connection to other organs
There is an occult relationship between the pineal gland and other organs of the body. For example, its activity has an effect on the heart, as an organ of the spiritual consciousness:
The aura of the Pineal Gland vibrates during the activity of the Consciousness in the Brain, and shows the play of the seven colors. This septenary disturbance and play of light around the Pineal Gland are reflected in the Heart, or rather in the aura of the Heart, which is negative to the brain in the ordinary man. This aura then vibrates and illumines the seven brains of the Heart, as that of the Pineal Gland illumines the seven centres in the Brain. If the Heart could, in its turn, become positive and impress the Brain, the spiritual Consciousness would reach the lower Consciousness. . . . This is the “memory of the Heart”; and the capacity to impress it on the Brain, so that it becomes part of its Consciousness, is the “opening of the Third Eye.”
The activity of the pineal gland, in its turn, is affected by that of the brain as a whole, and in particular by the medulla oblongata:
Of course, the normal and abnormal state of the brain, and the degree of active work in the medulla oblongata, reacts powerfully on the pineal gland, for, owing to the number of “centres” in that region, which controls by far the greater majority of the physiological actions of the animal economy, and also owing to the close and intimate neighborhood of the two, there must be exerted a very powerful “inductive” action by the medulla on the pineal gland.
The medulla oblongata is among the oldest evolutionary parts of the brain. Anatomically, it connects the higher levels of the brain to the spinal cord. It is responsible for regulating several basic functions of the autonomic nervous system which include respiration, the cardiac center (sympathetic and parasympathetic system), the vasomotor center, and the reflex centers of vomiting, coughing, sneezing, and swallowing. People who experience brain damage can still have functioning bodies, as long as the medulla oblongata is working. Damage to the medulla oblongata can be fatal. A variety of drugs and medications can cause changes in the function of the medulla oblongata, which can sometimes result in physical states which resemble death. Opiates and alcohol can both cause dysfunction until the body is able to express these substances, and in cases of overdose, it is possible to die because this area of the brain is not able to function normally. Sedatives can cause similar effects, as can hypothermia and coma.
Other occult connections are the following:
The Pineal Gland is the focus of the spiritual, hence inorganic, sensorium. Its action has nothing to do with the circulation of the Blood, but it is concerned with the spiritual fiery emanation that proceeds from the Blood. Further: the Pineal Gland, at the upper pole of the human body, corresponds with the Uterus (in the female and its analogue in the male) at the lower pole; the peduncles of the Pineal Gland corresponding with the Fallopian Tubes of the Uterus. The Pituitary Body is only the servant of the Pineal Gland, its torch-bearer, like the servants carrying torches that run before the carriage of a princess.
The right eye is the “Eye of Wisdom,” i.e., it corresponds magnetically with that occult centre in the brain which we call the “Third Eye” while the left corresponds with the intellectual brain, or those cells which are the organ on the physical plane of the thinking faculty.
In Hinduism the ājñā chakra, the subtle center located at the eyebrow region, is traditionally considered as the Third Eye. However, neither its position nor its functions agree with the Theosophical view of the Third Eye. C. W. Leadbeater connected the brow chakra on the etheric body with the pituitary gland rather than with the pineal. He connected the latter with the crown chakra, called sahasrāra in Hinduism. But, when considering the astral (instead of the etheric) chakras, he wrote:
The forces from both the sixth and seventh astral centres (which are between the eyebrows and on top of the head) usually converge on the pituitary body, when the etheric centre is aroused, and then vivify it and act through it. But there is a certain type of people . . . in whom the seventh astral chakra vivifies the pineal gland instead of the pituitary body, and it in that case forms a line of communication directly with the lower mental plane, without apparently passing through the astral plane in the ordinary way. Through that channel come for them the communications from within, while for the other type of people they come through the pituitary body.
Regarding the function of the awakened crown chakra, he wrote:
When the seventh centre is quickened, the man is able by passing through it to leave his body in full consciousness, and also to return to it without the usual break, so that his consciousness will be continuous through night and day. When the fire has been passed through all these centres in a certain order (which varies for different types of people) the consciousness becomes continuous up to the entry into the heaven-world at the end of the life on the astral plane, no difference being made by either the temporary separation from the physical body during sleep or the permanent division at death.
Pineal Gland & DMT
In his book, “Spirit Molecule”  Rick Strassman elaborates on the mystery of DMT and the Pineal Gland as follow:
The most general hypothesis is that the pineal gland produces psychedelic amounts of DMT at extraordinary times in our lives. Pineal DMT production is the physical representation of non-material, or energetic, processes. It provides us with the vehicle to consciously experience the movement of our life-force in its most extreme manifestations. Specific examples of this phenomenon are the following:
When our individual life force enters our fetal body, the moment in which we become truly human, it passes through the pineal and triggers the first primordial flood of DMT.
Later, at birth, the pineal releases more DMT.
In some of us, pineal DMT mediates the pivotal experiences of deep meditation, psychosis, and near-death experiences.
As we die, the life-force leaves the body through the pineal gland, releasing another flood of this psychedelic spirit molecule.
The pineal gland contains the necessary building blocks to make DMT. For example, it possesses the highest levels of serotonin anywhere in the body, and serotonin is a crucial precursor for pineal melatonin. The pineal also has the ability to convert serotonin to tryptamine, a critical step in DMT formation.
The unique enzymes that convert serotonin, melatonin, or tryptamine into psychedelic compounds also are present in extraordinarily high concentrations in the pineal. These enzymes, the methyltransferases, attach a methyl group—that is, one carbon and three hydrogens—onto other molecules, thus methylating them. Simply methylate tryptamine twice, and we have dimethyl-tryptamine, or DMT. Because it possesses the high levels of the necessary enzymes and precursors, the pineal gland is the most reasonable place for DMT formation to occur. Surprisingly, no one has looked for DMT in the pineal.
The pineal gland also makes other potentially mind-altering substances, the beta-carbolines. These compounds inhibit the breakdown of DMT by the body’s monoamine oxidases (MAO). One of the most striking examples of how beta-carbolines work is ayahuasca. Certain plants that contain beta- carbolines are combined with other plants that contain DMT to make this psychedelic Amazonian brew, which allows the DMT to become orally active. If it weren’t for the beta-carbolines, MAO in the gut would rapidly destroy this swallowed DMT, and it would have no effect on our minds.
It is uncertain whether beta-carbolines by themselves are psychedelic. However, they do markedly enhance the effects of DMT. Thus, the pineal gland may produce both DMT and chemicals that magnify and prolong its effects.
Under what circumstances might the pineal gland make DMT instead of the minimally psychoactive melatonin? For this to happen, there needs to be an overriding of one or more of the following constraints normally pre- venting pineal DMT production:
• The cellular security system around the pineal gland;
• The presence of an anti-DMT compound in the pineal gland;
• The low activity of the methyltransferase enzymes that produce DMT; and
• The efficiency of the monoamine oxidase enzymes breakdown of DMT.