Light is produced when atoms release stored energy. In fact material atoms are made of energy  and all their energy  can be released as light(electromagnetic radiation)according to    E=mc^2
Conversely  electromagnetic energy can
be transformed into material particles  such as electrons and positrons  .
Thus matter and energy are interconvertible static and kinetic forms of one substance.
Electromagnetic photons  are massless and chargeless.But when thisy kinetic energy is transformed into static material particles, tbe properties of mass and charge  emerge. These "emergent" properties must have existed in a potential 
unmanifest state within the photon (or how could theze properties  miraculously          appear out of nothing and nowhere?)    
Perhaps because photons do not exist in a static state but are always moving at light speed, tbese properties (like "time") do not cease to exist but cease to be measureable/detectable. How would you measure tbe mass of a particle moving at light speed.?
Photons are the basic quantum unit of the action of electromagnetic radiation. They have no mass and no charge. They travel through space at 186,000 miles per second with no loss in energy until they collide with other particles. Thus photons,
( tiny particle-waves with no mass, no charge, no time, neither matter nor anti-matter) constitute one of the basic units of action in physics.
It is as if photons exist in space, but not in time:
Imagine that you are a photon travelling through space at the speed of light. If you were to look at your watch, you would, according to the theory of relativity discover that time was standing still. Hence you could travel to the very edges of the known universe without aging a single day, although, to an observer on earth, it would take you three billion years to get there.
In other words,at light speed it is possible to traverse infinite distance in zero time; i.e. instantaneously!
A photon, when it is annihilated, is able to create particles of matter and anti-matter which have both mass, charge, and time,.
How can "massless" photons materialize into particles possesing mass and charge?
Conversely when particles of matter and anti-matter come into contact with each other,  their measurable properties of mass,charge,time are annihilated and photons are produced   (the  "mass,charge,time" properties cease to be measureable)
A photon  with a specific energy, "E" ,
although  it is experimentally "massless"
nevertheless has a mathematicaly calculatable finite mass  of  m=E/c^2.
E=mc^2, 
c^2 =E/m
Light is produced when atoms release stored energy. In fact material atoms are made