By this I think you mean 'disperse into its spectral colours'.
Visible light is a mixture of frequencies, hence wavelengths, each having a particular refractive index n where n=ratio of speeds between one material and another (air and glass, for example). The greater the refractive index, the more a ray of light will change direction between the two media. Red light has a lower n than blue light, hence is refracted less. So, a narrow beam of white light when incident at the right angle on a prismatic block of glass will emerge in different places - so we see the colours of the visible spectrum.