Sunlight carries every colour
Sunlight looks white, but it is a mix of every colour of the rainbow. Each colour travels as a wave of a different size: red has longer waves, blue and violet shorter ones.
Read also: Why you can't tickle yourself and Why do we dream? What science has found so far.
Air scatters blue the most
Crossing the atmosphere, light hits gas molecules, mostly nitrogen and oxygen. Those molecules scatter light in every direction, and the scattering is far stronger for short waves. That is why blue spreads across the whole sky and reaches your eyes from every direction. NASA explains the effect this way on its educational site.
Scientists call it Rayleigh scattering, after the British physicist who described it in the 19th century.
Source: NASA Space Place, Why is the sky blue?.
If violet is shorter, why is the sky not violet?
Violet scatters even more than blue, but three things work against it: the Sun emits less violet, part of it is absorbed high in the atmosphere, and our eyes are far more sensitive to blue. What the brain ends up seeing is a light blue sky.
Why the sunset turns orange
Late in the day, sunlight crosses a much longer stretch of air to reach you. Along the way almost all the blue has been scattered sideways. What remains are the long waves, yellow, orange and red, painting the horizon. Dust, smoke and pollution can make it even redder.
And why clouds are white
If air scatters blue more, why does a cloud look white? Because size changes everything. Gas molecules are much smaller than the wavelength of light and scatter short waves more. Water droplets in a cloud are large enough to scatter all colours almost equally, and all colours together look white. A cloud heavy with water lets less light through and looks grey.
The ocean adds a second effect: according to the US ocean service, water itself absorbs long wavelengths, like red, and lets blue travel deeper, scattering it back.
Source: NOAA Ocean Service, why is the ocean blue.
Sources
- NASA Space Place. Why is the sky blue? https://spaceplace.nasa.gov/blue-sky/en/
- NOAA National Ocean Service. Why is the ocean blue? https://oceanservice.noaa.gov/facts/oceancolor.html
Frequently asked questions
Why is the sky blue?
Because air molecules scatter short-wavelength blue light far more than other colours. The effect is called Rayleigh scattering.
Why is the sky not violet?
The Sun emits less violet, part of it is absorbed high in the atmosphere, and our eyes are more sensitive to blue.
Why is the sunset orange?
Late in the day light crosses more air, so blue scatters away and yellow, orange and red remain.
Why are clouds white?
Water droplets are large and scatter all colours almost equally, and the sum of all colours is white.