Why is the sky blue?

Sunlight is a mix of every colour. Air molecules scatter short blue waves much more than long red ones, so blue light reaches your eyes from every direction in the sky.

Sunlight is a mix of every colour. Air molecules scatter short blue waves much more than long red ones, so blue light reaches your eyes from every direction in the sky.
Why is the sky blue?: an interactive picture drawn by Why Tho?

Why tho? Three levels deeper

Why does blue scatter more than red?

Air molecules are far smaller than a wave of light. The light makes their electrons jiggle, and they send light back out in every direction. This works much better for short waves: scattering grows like one over the wavelength to the fourth power, so blue light (about 450 nm) scatters roughly five to six times more than red (about 700 nm).

Then why isn't the sky violet?

Violet scatters even more, but sunlight has less violet in it to begin with, some of it is absorbed high in the atmosphere, and our eyes are much less sensitive to violet than to blue. The mix we see comes out sky blue.

So why are sunsets red?

When the Sun is low, its light crosses many times more air to reach you. Most of the blue is scattered out of the beam on the way, so the light that arrives is mostly red and orange.

The short version

White sunlight is every colour of the rainbow travelling together. When it enters the atmosphere it meets nitrogen and oxygen molecules, which are much smaller than the light's waves. They scatter some of the light sideways, and they scatter short waves (blue) far more than long waves (red). Look anywhere in the sky away from the Sun and you are seeing that scattered blue light.

A good way to remember it

Think of the air as a crowd that bounces blue light around and lets red light walk straight through. During the day, the bounced blue comes at you from every direction. At sunset, the light has to push through so much crowd that almost all the blue has been bounced away before it reaches you.

Common mix-ups

Check yourself

The Moon has no air. What colour is its sky in the middle of the day?

Answer

Black. With no air, nothing scatters sunlight toward your eyes, so you see the bright Sun against a black sky.

Ask Why Tho? your own question