How rainbows form
AA rainbow appears when sunlight passes through raindrops in the air. As light enters a droplet, it slows and bends, an effect called refraction. Inside the drop the light reflects off the back surface and bends again as it leaves, splitting the white sunlight into its separate colours.
BBecause each colour bends by a slightly different amount, they emerge at different angles and spread into the familiar arc of red, orange, yellow, green, blue and violet. A rainbow can therefore only be seen when the Sun is behind the observer and rain is falling in front of them.