Why Do Rainbows Form?
When sunlight shines into raindrops, it bends as it enters the water. Each color bends by a slightly different amount, so the white light spreads out into a band of colors with red on top and violet underneath.
A rainbow is sunlight that has been sorted into its colors by millions of raindrops. To see one, you need two things at once: sunshine and drops of water floating in the air. That is why rainbows often show up just after a rain shower, when the Sun breaks through.
White light is secretly many colors
Sunlight looks white, but it is a blend of every color we can see. Each color is light with a different wavelength, meaning a different size of wave. Red has the longest waves we can see, about 700 nanometers from peak to peak. Violet has the shortest, about 380 nanometers. Orange, yellow, green and blue fall in between.
Normally all those colors travel together, so we see plain white. A rainbow happens when something pulls them apart. In a rainbow, the separated colors line up in order of their wavelengths, so the band always runs from red through orange, yellow, green and blue to violet.
Light bends when it changes speed
Light moves at different speeds in different materials. It travels slower in air than in empty space, and even slower in water. When a beam of light crosses from one material into another, the change in speed makes it turn a little. This bending is called refraction.
Each color bends a different amount
Here is the key. Refraction does not bend all colors equally. Shorter wavelengths bend more than longer ones. So when white light enters water or glass, violet and blue turn the most and red turns the least. The colors fan out, each heading in a slightly different direction.
Isaac Newton showed this in 1665 using a prism, a wedge-shaped piece of glass. Sunlight went in white and came out spread into a strip of colors. Each color left at its own angle.
A raindrop is a tiny prism
A raindrop does the same job as Newton’s prism. Sunlight enters the drop and bends. Inside, the light bounces around and then exits, bending again. Because the colors bend by different amounts, they leave the drop spread apart.
One drop sends only a little bit of color toward your eyes. But the sky is full of drops. Drops at slightly different heights send different colors your way. Together, millions of drops build up the full curved band. In the rainbow you see, the longest wavelength, red, sits on the top edge and the shortest, violet, sits on the bottom.
Try it at home
A glass of water can bend sunlight in a similar way, so you can make a small band of colors at home with the experiment below.
The next time rain and sunshine happen together, look around the sky. Somewhere, millions of raindrops may be bending and sorting sunlight into colors just for you.
Try it at home: Make a rainbow with a glass of water
You need:
- A clear glass full of water
- A sunny window
- A sheet of white paper
- Set the glass on a windowsill or table where direct sunlight shines through it.
- Put the white paper on the floor or table on the shady side of the glass.
- Move the paper and tilt the glass slightly until a small band of colors appears.
- Notice the order of the colors. Is red on one side and violet on the other?
Grown-up check: Never look straight at the Sun. Wipe up spills so nobody slips.
Fun facts
- Isaac Newton used a glass prism in 1665 to show that white light splits into colors that each bend by a different amount.
- Violet light has waves about 380 nanometers long and red light about 700. A nanometer is a billionth of a meter.
Key words
- refraction
- The bending of light when it passes from one material, like air, into another, like water.
- spectrum
- The full band of colors that white light can be split into.
- prism
- A clear block of glass with flat, angled sides that splits light into colors.
Quick quiz
What did you think?
Tap one. We only count the button, never who pressed it: no names, no accounts, no cookies.
Thanks! Your reaction was counted.
Still have a question? Kids: ask a grown-up to email our editors for you. Found a mistake? Send a correction.
Sources
Pages our editors opened and checked for this answer.
- The Appearance of the Sky | Center for Science Education — retrieved November 23, 2026
- Wave Behaviors - NASA Science — retrieved November 23, 2026
- Visible Light - NASA Science — retrieved November 23, 2026
Related questions
- Why Is the Sky Blue?
Sunlight looks white, so why is the daytime sky blue? Learn how air molecules scatter blue light in every direction, with an easy kitchen test.
- Why Is the Sunset Red?
Sunsets glow red and orange while the noon sky is blue. Learn how the long path of evening sunlight, dust and smoke create sunset colors.
- Why Do We See Lightning Before We Hear Thunder?
Lightning flashes first and thunder rumbles later. See why light beats sound, how to count the seconds, and how thunder is made.
- Why Do Magnets Stick to Some Metals?
Why does a magnet grab a fridge door but not a soda can? How electrons, magnetic domains and poles make magnets stick, for curious teens.