Jesse Ideas

Aug 09, 2026 RAW
Article

What is Rainbow Color Code: HEX & RGB Values

Did you know that the entire spectrum of visible light can be broken down into seven distinct colors? And each of these colors corresponds to a specific wavelength, which has been standardized and assigned a code. This is what's known as a rainbow color code. Let's delve into this fascinating world of color science.

the rainbow challenge poster with different colors
the rainbow challenge poster with different colors

But first, let's understand how light is perceived as color. It all began in 1672 when Sir Isaac Newton passed white light through a prism, splitting it into seven colors: red, orange, yellow, green, blue, indigo, and violet. These seven colors became known as the 'Newton's prismatic spectrum' or simply, the visible light spectrum.

What Is the Rainbow Color Order? List of Rainbow Colors
What Is the Rainbow Color Order? List of Rainbow Colors

Understanding Color Codes

The color codes we use today initially emerged from the need to standardize color in the printing and digital domains. But the physics behind color codes owe their origins to Sir Isaac Newton's experiments.

Rainbow colour pallet pastel colour aesthetic lgbt
Rainbow colour pallet pastel colour aesthetic lgbt

However, Newton's jednej series of colors (known as the Newton's Seven) was later replaced by the modern 'rainbow series' of six colors (adding a seventh color, violet, into Newton's first two colors, indigo and violet), as we know them today.

Additive Color Model

Organized & Aesthetic: Color Codes for Google Sheets in Every Shade🌟
Organized & Aesthetic: Color Codes for Google Sheets in Every Shade🌟

The lighting system in our digital devices, such as computer screens or smartphones, uses red, green, and blue (RGB) to create all the colors we see. This is known as the additive color model. You might wonder, why not seven colors? The seventh color, violet, is a product of light with a very short wavelength, which is difficult to reproduce digitally.

In this model, the RGB color code works as follows: each color is assigned a value between 0 and 255, with 0 being absence of color (full absence giving black) and 255 being the vibrant color itself (full presence). For instance, pure red is RGB(255, 0, 0), while pure green is RGB(0, 255, 0).

Subtractive Color Model

Pink Floyd
Pink Floyd

In contrast, the color system used in physical color, like paints or dyes, is the subtractive model. Here, instead of adding light to create color, we subtract light to create it. This model is based on the three primary colors: cyan, magenta, and yellow (CMY).

In this model, color is represented by a percentage of each color present in an ink or dye. For example, 100% cyan, 100% magenta, and 100% yellow would make black, as they absorb all visible light. This is why your favorite printer's toners are CMYK instead of CMY. The 'K' stands for black, added to keep the subtractions simpler.

Exploring Rainbow Colors & Their Codes

the pantone color chart with different colors and numbers for each part of the page
the pantone color chart with different colors and numbers for each part of the page

Though the rainbow colors have been part of human imagination for centuries, the standardization of these colors, and their respective codes, came much later with the advent of science and technology.

Starting from the left of the rainbow spectrum, the colors and their RGB codes are as follows:

Colour codes / dress to impress
Colour codes / dress to impress
Rainbow Colors in Order
Rainbow Colors in Order
Color Palette
Color Palette
Rainbow Colors
Rainbow Colors
Colors of the Rainbow and Their Meanings in Different Cultures (2026) β€’ Colors Explained
Colors of the Rainbow and Their Meanings in Different Cultures (2026) β€’ Colors Explained
Set of 20 RGB Color Codes
Set of 20 RGB Color Codes
Five Color Rainbow Color Scheme
Five Color Rainbow Color Scheme
Html カラーコード
Html カラーコード
Eat the Rainbow: Color-Coded Nutrition Guide (Colorful Healthy Eating) 🌈
Eat the Rainbow: Color-Coded Nutrition Guide (Colorful Healthy Eating) 🌈
Pastel Rainbow Palette | Hex Codes 🌈🎨  Follow for More daliy palette 🎨.
Pastel Rainbow Palette | Hex Codes 🌈🎨 Follow for More daliy palette 🎨.
Coolors.co
Coolors.co
7 (Seven) Colours of the rainbow in Order Β» Onlymyenglish.com
7 (Seven) Colours of the rainbow in Order Β» Onlymyenglish.com
pastel paradise πŸŽ€
pastel paradise πŸŽ€
Color Coding
Color Coding
Rainbow Color Palette (Vibrant and Pastel Schemes) - Free Printables, Lettering, SVG Files, Tools & Apps
Rainbow Color Palette (Vibrant and Pastel Schemes) - Free Printables, Lettering, SVG Files, Tools & Apps
the color code for all different font styles and colors, including black, white, red, blue, green, yellow, pink, purple, orange
the color code for all different font styles and colors, including black, white, red, blue, green, yellow, pink, purple, orange
an array of colorful numbers on a black background
an array of colorful numbers on a black background
  • Red: RGB(255, 0, 0)
  • Orange: RGB(255, 165, 0)
  • Yellow: RGB(255, 255, 0)
  • Green: RGB(0, 255, 0)
  • Blue: RGB(0, 0, 255)
  • Indigo: RGB(75, 0, 130)
  • Violet: RGB(238, 130, 238)

This code set is widely used in the fields of design, graphics, and technology to represent and manipulate colors digitally. However, the possibilities of light and color go beyond the standard seven colors, offering an infinite spectrum of hues and shades.

Understanding the rainbow color code not only helps in creating heroes and villains in our favorite superhero movies but also helps in recreating the beauty of a sunrise in digital photography. So, the next time you marvel at a sunset, you'll understand that the dance of colors is more than just pretty - it's physics in play.