A rainbow is a beautiful natural optical phenomenon that appears in the sky when sunlight interacts with water droplets in the atmosphere. It is produced by the refraction, reflection, and dispersion of light, which separate white sunlight into a range of visible colors. A rainbow usually appears when rain and sunshine occur at the same time, forming a colored arc across the sky. Although it looks like a physical object, it has no fixed location and cannot be touched. Throughout history, rainbows have inspired scientific curiosity, cultural stories, religious interpretations, and popular legends, including the familiar tale that a pot of gold can be found at the end of one.
How Is a Rainbow Formed?
A rainbow is most likely to appear when sunlight and rain are present at the same time. For an observer to see a primary rainbow, the Sun must generally be behind them and relatively low in the sky, no more than about 42 degrees above the horizon. Rain droplets must be in front of the observer, where sunlight can reach them. This is why rainbows are often seen after a shower, when the clouds begin to clear while rain is still falling in the opposite part of the sky.
To understand how a rainbow forms, it helps to remember that white sunlight is made up of many different wavelengths of visible light. When these wavelengths are mixed together, the eye perceives them as white. Light normally travels in a straight line, but its direction changes when it passes from one material into another. As sunlight enters a raindrop from the air, it slows down and bends, a process called refraction. Different wavelengths bend by slightly different amounts, separating the light into colors. The light then reflects off the inside back surface of the droplet and travels toward the front again. As it leaves the droplet and returns to the air, it is refracted once more. The separated colors reach the observer at slightly different angles, creating the familiar rainbow.

Rainbows do not appear only in the sky after rainfall. They can also be seen in the spray from a garden sprinkler, in the mist at the base of a waterfall, or wherever sunlight shines through suitable water droplets. A similar separation of white light into colors can be produced without rain, for example by passing sunlight through a glass prism. In each case, the different wavelengths of visible light are refracted by different amounts, producing the familiar sequence of colors.
Why Do Rainbow Colors Appear in This Order?

In a primary rainbow, the colors usually appear from the outer edge to the inner edge in this order: red, orange, yellow, green, blue, indigo, and violet. This arrangement is caused by dispersion: different wavelengths of light are refracted by different amounts as they enter and leave a raindrop. Violet light has a shorter wavelength and bends more strongly than red light, which has a longer wavelength. The different colors therefore emerge from the droplets at different angles and form the recognizable sequence.
Is a Rainbow Really Shaped Like an Arc?
Although a rainbow usually looks like an arc, its full shape is actually a circle. Raindrops are approximately spherical, and the light they send toward an observer forms a circular pattern around the point directly opposite the Sun. From the ground, the horizon and the Earth’s surface block the lower part of the circle, leaving only the familiar arc visible. The lower the Sun is in the sky, the larger the visible portion of the circle can become. From an aircraft, when the observer has an unobstructed view, it may be possible to see a complete circular rainbow.

Sometimes a double rainbow appears. The primary rainbow is produced when sunlight enters a droplet, refracts, reflects once inside it, and refracts again as it leaves. A secondary rainbow forms when the light is reflected twice inside the droplet before emerging. It appears at a larger angle—about 50 to 53 degrees from the antisolar direction rather than approximately 42 degrees for the primary rainbow. Because the light undergoes an additional reflection, the secondary rainbow is usually fainter. Its colors also appear in reverse order: red is on the inner edge and violet on the outer edge.

The History and Legends of Rainbows
The ancient Greek philosopher Aristotle was among the earliest thinkers to study rainbows systematically. Later writers, including the Roman philosopher Seneca the Younger, discussed different explanations for how they formed and noted their relationship to the position of the Sun. The medieval Arab scholar Ibn al-Haytham also investigated light and vision, contributing to the broader scientific understanding of optics. A major advance came from the Persian astronomer Qutb al-Din al-Shirazi and his student Kamal al-Din al-Farisi, who developed explanations involving the refraction and reflection of light inside water droplets. Al-Farisi used a glass sphere filled with water in a darkened room to model the process and study how the colors were produced.

In the thirteenth century, Roger Bacon studied the geometry of rainbows and estimated their angular size. Around the beginning of the fourteenth century, Theodoric of Freiberg developed an important theoretical explanation for both primary and secondary rainbows by studying how light behaves inside individual water droplets. René Descartes later provided a detailed account of the phenomenon. In the seventeenth century, Isaac Newton used a glass prism to show that white light is made up of different colors. He also demonstrated that different colors refract by different amounts, helping establish the scientific explanation for the main features of a rainbow.
Rainbows have also held symbolic meanings in many cultures. In Greek mythology, the goddess Iris was associated with the rainbow and was believed to act as a messenger between the gods and humanity. European folklore popularized the story of a pot of gold hidden at the end of the rainbow. In modern times, the rainbow has been adopted by a variety of social, cultural, and political movements. It has served as a symbol of peace and cooperation, appeared in the imagery of the anti-apartheid movement in South Africa, and become widely recognized as a symbol of LGBTQ+ pride. Rainbow colors have also been used in commercial logos, including Apple’s historic multicolored logo, and by political coalitions in several European countries. The meaning of the symbol therefore depends on the historical and cultural context in which it is used.
