On this page
Have you ever wondered why the sky is bright blue during the middle of the day but turns a brilliant fiery red or orange as the sun begins to set? This dramatic shift in colour is a classic example of Rayleigh scattering, a process where light bounces off gas molecules like nitrogen and oxygen in the Earth's atmosphere.
Understanding why the colour changes depends on two key ideas: how strongly different colours of light scatter, and how much air the light has to travel through before it reaches you.
What is the Rayleigh scattering formula?
White light from the Sun is actually a mixture of all the visible colours of the rainbow, and each colour has its own specific wavelength. According to HyperPhysics, the intensity of Rayleigh scattering is inversely proportional to the fourth power of the wavelength, often written as 1/λ⁴.
This mathematical relationship means that shorter wavelengths scatter far more effectively than longer ones. Blue light, which has a wavelength of around 400 nm, scatters about 9.4 times more efficiently than red light, which has a longer wavelength of 700 nm. When the sun is high in the sky, this scattered blue light bounces in all directions across the upper atmosphere, giving the sky its familiar blue backdrop.
Why are sunsets red?
The redness of a sunset comes down to the sheer distance the light must travel through the air. In astronomy and atmospheric physics, the path sunlight takes through the atmosphere is measured as "air mass".
When the sun is at the zenith—directly overhead at noon—the air mass is exactly 1.0. The light is taking the shortest, most direct path to reach the ground. But as the Earth rotates and the sun drops toward the horizon, the sunlight passing at grazing incidence must pass through a much greater thickness of air than when it is overhead, according to HyperPhysics.
Across this vast distance, the intense scattering of shorter wavelengths becomes an insurmountable obstacle course. Because blue light scatters so heavily, almost all the blue and violet light is knocked out of the direct beam long before it can reach your eyes. The longer red and orange wavelengths, which do not scatter easily, survive the long journey. When you look at a sunset, you are seeing the resilient red light that made it straight through the dense lower atmosphere.
What about dust and haze?
While Rayleigh scattering handles the gas molecules, another type of scattering takes over when the air is filled with larger particles. This is called Mie scattering.
When sunlight hits water droplets, dust, or pollution, the light scatters differently because these particles are much larger than a wavelength of visible light. Mie scattering does not follow the strict 1/λ⁴ rule. Instead, it scatters all wavelengths more evenly. This is why clouds, which are made of relatively large water droplets, look white or grey rather than blue. When there is a lot of dust or smoke in the air, Mie scattering can make the colours of a sunset look even more muted or shift the palette toward deeper, murkier reds.
How can you test this in a scattering simulation?
Visualising an inverse fourth-power law like 1/λ⁴ can be challenging when you are just reading equations from a textbook. It is hard to picture exactly how rapidly the scattering drops off as the wavelength increases. This is where interactive tools can help you bridge the gap between a formula and a real-world result.
If you want to see how different wavelengths behave across varying path lengths, the Fermi Simulation Lab lets you run these scenarios yourself. Interactive simulations are built for the ideas that are easier to see than to read. You can adjust the wavelength slider or change the atmospheric thickness and immediately watch how the scattering intensity responds, helping to turn an abstract algebraic rule into an intuitive, physical picture.
Once you have a feel for how scattering works, you can explore other optical effects that govern the sky. For instance, atmospheric refraction bends light as it enters the Earth's atmosphere, which is why stars twinkle and why the sun appears slightly flattened at sunset. Meanwhile, dispersion by a glass prism separates white light into its component colours based on how much each wavelength bends, rather than how much it scatters.
Whether you are revising optics for JEE or simply exploring the physics of the natural world, testing the variables yourself is one of the best ways to ensure the concepts stick.



