A phosphene is an entoptic phenomenon characterized by the experience of seeing light without light actually entering the eye. The word phosphene comes from the Greek words phos (light) and phainein (to show). Phosphenes can be directly induced by mechanical, electrical, or magnetic stimulation of the retina or visual cortex as well as by random firing of cells in the visual system. Phosphenes have also been reported by meditators, people who go for long periods without visual stimulation (also known as the prisoner's cinema) or who are under the influence of drugs, especially a hallucinogen.
The most common phosphenes are pressure phosphenes, caused by rubbing the closed eyes. They have been known since antiquity, and described by the Greeks. The pressure mechanically stimulates the cells of the retina. Experiences include a darkening of the visual field that moves against the rubbing, a diffuse colored patch that also moves against the rubbing, a scintillating and ever-changing and deforming light grid with occasional dark spots (like a crumpling fly-spotted flyscreen), and a sparse field of intense blue points of light. Pressure phosphenes can persist briefly after the rubbing stops and the eyes are opened, allowing the phosphenes to be seen on the visual scene. Herman Helmholtz and others have published drawings of their pressure phosphenes. One example of a pressure phosphene is demonstrated by gently pressing the side of your eye and observing a colored ring of light on the opposite side, as detailed by Isaac Newton.
Another common phosphene is “seeing stars,” from a sneeze, a heavy and deep cough, blowing of the nose, a blow on the head or low blood pressure (such as on standing up too quickly or prior to fainting). It is possible these involve some mechanical stimulation of the retina, but they may also involve mechanical and metabolic stimulation of neurons of the visual cortex or of other parts of the visual system.
Less commonly, phosphenes can also be caused by some diseases of the retina and nerves. The British National Formulary lists phosphenes as an occasional side effect of at least one anti-anginal medication (available only by medical prescription in the United Kingdom).
The name "phosphene" was coined by JBH Savigny, better known as the ship's surgeon of the wrecked Medusa. It was first employed by Serre d'Uzes to test retinal function prior to cataract surgery.
Phosphenes have also been created by electrical stimulation of the brain as early as 1929 by neurologist Otfrid Foerster. Brindley and Lewin (1968) inserted a matrix of stimulating electrodes directly into the visual cortex of a 52-year-old blind man, using small pulses of electricity to create phosphenes. These phosphenes were points, spots, and bars of colorless or colored light.  Brindley and Rushton (1974) used the phosphenes to create a visual prosthesis, in this case by using the phosphenes to depict Braille spots.
In recent years, researchers have successfully developed experimental brain-computer interfaces or neuroprosthesis that stimulate phosphenes to restore vision to people blinded through accidents. Notable successes include the human experiments by William H. Dobelle and Mark Humayun and animal research by Dick Normann.
Phosphenes have also been created by intense, changing magnetic fields, such as with transcranial magnetic stimulation. These fields can be positioned on different parts of the head to stimulate cells in different parts of the visual system. They also can be induced by alternating currents that entrain neural oscillation as with trancranial alternating-current stimulation. In this case they appear in the peripheral visual field.
Most vision researchers believe that phosphenes result from the normal activity of the visual system after stimulation of one of its parts from some stimulus other than light. For example, Grüsser et al. showed that pressure on the eye results in activation of retinal ganglion cells in a similar way to activation by light. An ancient, discredited theory is that light is generated in the eye.  A version of this theory has been revived, except, according to its author, that "phosphene lights are [supposed to be] due to the intrinsic perception of induced or spontaneous increased biophoton emission of cells in various parts of the visual system (from retina to cortex)" 
In 1988, David Lewis-Williams and T. A. Dowson published an article about phosphenes and other entoptic phenomena. They argued, among other things, that non-figurative art of the Upper Paleolithic depicts actual visions of phosphenes and neurological “form constants,” probably enhanced by hallucinogenic drugs.
Phosphenes were used as a learning technique by French scientist and scholar, Francis Lefebure.