Tools Developer Tools Web Safe Color Generator

Web Safe Color Generator: Copy 216 Hex Codes

Developer Tools Active

Click any of the 216 classic web safe swatches to copy its hex code, or let the tool pick one at random.

Web Safe Color Generator

🎨 Web Safe Color Generator

Browse and generate the standard 216 web-safe color palette (RGB values in multiples of 51 / 0x33).

🎨 216 Web Palette
Palette Size
216 Colors
Color Step
0x33 (51)
Selected Swatch
None yet

Rate This Tool

Your feedback helps others discover great tools

–
out of 5
No ratings yet

Tap a star to rate:

About This Tool

Ever wonder why a background looked fine on your screen but muddy on an old monitor? The Web Safe Color Generator shows the classic set of 216 colors that older displays could render the same way. It is a browser tool for designers, developers, and students who want a known, repeatable color list.

This tool does not ask for any input. It draws every web safe color as a clickable swatch. You can copy a hex code with one click, or let it pick a random one for you.

Table of Contents

  • What the Tool Does
  • How to Use It, Step by Step
  • How the 216 Colors Are Built
  • Worked Example
  • How to Read the Results
  • Where Web Safe Colors Still Help
  • Limitations and Assumptions
  • FAQs About the Web Safe Color Generator

What the Tool Does

The tool builds one fixed palette and shows it as a grid. Nothing is random unless you press the random button. The parts you see are listed below.

  • Palette Size: a label that reads 216 Colors, the full web safe set.
  • Color Step: a label that reads 0x33 (51), the gap between each channel value.
  • Selected Swatch: a readout that reads None yet until you click a swatch.
  • Color Grid: 216 swatches, each showing its hex code. Click one to copy it.
  • Pick Random Web Safe Color: a button that selects one swatch at random and copies it.

How to Use It, Step by Step

  1. Look at the grid of 216 colored squares below the tool.
  2. Read the hex code printed near the bottom of each swatch.
  3. Click any swatch to copy its hex code to your clipboard.
  4. Watch the Selected Swatch readout change to the color you clicked.
  5. Press Pick Random Web Safe Color if you want the tool to choose one for you.
  6. Paste the copied hex code into your CSS, design file, or notes.

How the 216 Colors Are Built

A hex color has three channels: red, green, and blue. Each channel in this set can hold one of six values only. Those values are 00, 33, 66, 99, CC, and FF in hex.

In plain numbers those are 0, 51, 102, 153, 204, and 255. Every step is 51 apart, which is 0x33 in hex. The tool pairs every red choice with every green and blue choice.

6 Red Valuesx6 Green Valuesx6 Blue Values=216 Colors
  • Allowed channel values: 00, 33, 66, 99, CC, FF.
  • Count of colors: 6 times 6 times 6, which equals 216.
  • Order in the grid: red changes slowest, then green, then blue.

Worked Example

Say you want the shade #336699. The tool matches it because every channel is a valid step.

ChannelHexDecimal
Red3351
Green66102
Blue99153

All three values sit in the allowed set, so #336699 is web safe. In the grid it is the 52nd swatch. The first swatch is #000000, which is black, and the last is #FFFFFF, which is white.

Pure red #FF0000 is also in the set, since FF and 00 are both allowed. A shade like #123456 is not, because 12, 34, and 56 are not steps of 51.

How to Read the Results

Palette Size and Color Step are fixed facts about the set, not values you change.

Selected Swatch shows the hex code of the last swatch you clicked. It reads None yet before you click anything.

When you click a swatch, the tool copies that hex code and shows a small confirmation message. The random button does the same thing with a color it picks.

Where Web Safe Colors Still Help

Modern screens show millions of colors, so the old display limit is mostly gone. Still, a short, fixed list has real uses today.

It gives a small set to learn hex notation with, since the math is easy. It also helps when you want tidy, round hex values in a style guide. If you need the matching decimal values, the hex to RGB converter turns any code into red, green, and blue numbers.

These colors are not chosen for contrast or accessibility. Always test a text and background pair for readability. The color contrast checker measures the ratio against common standards.

To build a color by typing channel numbers, use the RGB color generator. To confirm a hex code is valid before you use it, the hex color validator checks the format. For broader ideas, the random color palette generator builds full schemes. More options live in the developer tools hub.

Limitations and Assumptions

  • The palette is fixed at 216 colors. You cannot add, remove, or edit the list.
  • There is no color wheel or hex input box. The old guide described those, but the code has neither.
  • Copy uses the browser clipboard and shows a visible confirmation. If the clipboard is blocked, the tool tries a backup copy method.
  • The tool does not check contrast, color blindness, or accessibility. It only lists colors.
  • The random button uses a general random source, which is fine for picking a color but is not secure randomness.
  • Web safe colors are a legacy idea. They are not required for modern sites.

FAQs About the Web Safe Color Generator

What is a web safe color?

It is one of 216 colors. Each red, green, and blue value is 0, 51, 102, 153, 204, or 255. Older displays could show these without dithering.

How many web safe colors are there?

There are exactly 216. That comes from 6 choices per channel times three channels, which is 6 times 6 times 6.

Does this tool let me enter my own color?

No. It only shows the fixed 216 palette and lets you click or randomly pick from it. There is no input box for a custom hex value.

How do I copy a color?

Click any swatch in the grid. The tool copies that hex code to your clipboard and shows a short confirmation message.

Do I still need web safe colors today?

Rarely. Modern screens show millions of colors, so the limit no longer applies. The set is still handy for teaching and for tidy, round hex values.

Are these colors accessible for all readers?

Not by default. Being web safe says nothing about contrast. Test each text and background pair with a contrast tool before you ship it.

This calculator gives general estimates only and is not professional advice. Reviewed for general accuracy by Prof. Dr. Khalil Mudassar, PhD.

Category: Developer Tools

You May Also Like

View All