Many people often ask that how does light travel in space without any medium. But answer is that, it doesn’t. The vacuum is the medium which permits light to travel in space. Now even the physicists also have given up the abstract idea of empty space, that is, space having no fields, whatsoever. They also have given up the conventional idea that the matter is substantially different from the fields. It is in fact, not. The math which is needed to describe the physical vacuum is exactly the same as what is needed to describe matter. Light travels faster in vacuum then in any other material.
Light is no different, it is just a property of vacuum. Just like sound is property of liquids, solids and gases. Another reasoning is that light is a type of electromagnetic radiation, which is amongst one of the four fundamental forces of nature and as such it do not require and any medium for propagation.
Light in fact has got nothing to do with space. In fact, it is the property of the electromagnetic field when it is undergoing some kind of change. This field radiates in space in all the directions from the point of origin. This field is invisible in nature and can only be felt by parties that carry some charge, whenever the field is changed. Like for example by sudden alteration of the position of the source, a kink develops in the field which propagates in the space with speed of light. Therefore, space simply acts as a passive container for the electro magnetic field, which in turn is the medium through which light propagates.
When there is no electromagnetic in space, the light will also not travel, as in the case of closed shield box. The light moves in a straight line only when it is not moving through anything at all, that is, vacuum. Whenever, the light travels through water, glass or anything else its behaviors changes. The direction of light in these cases basically changes due to two phenomenon, these are refraction and reflection. Reflection is when the light bounces off something whereas refraction is when the light one medium to another, both having different densities.
These two phenomenons’ either changes the direction of light or bend the light. Light only travels at constant speed, which we usually refer to as “speed of light”.