GameParticles
Colors

What Color Is This? Find the HEX Code and Name of a Color

What color is this? Identify any color from an image or your screen, get its HEX code, then match it to the closest color name. Step-by-step methods inside.

Updated

To find out what color something is, get its HEX code first and its name second. Sample the color from an image or from your screen to get a code such as #3B82F6, then match that code against a list of named colors to get a name such as royal blue. The code is the exact answer; the name is the nearest human-readable label.

Step 1: get the color into an image

If the color is already in an image file, skip ahead. If it is on your screen, in a web page, an app or a video, take a screenshot:

  • Windows: press Windows + Shift + S and drag over the area.
  • Mac: press Command + Shift + 4 and drag over the area.
  • Phone: use the normal screenshot buttons, then crop.

If the color is on a physical object, photograph it in daylight, away from colored walls and without flash. The section on accuracy below explains why this matters.

Step 2: extract the HEX code

Open the Color Palette Extractor and drop the image in, or click to choose a file. It accepts PNG, JPG, WebP, GIF and SVG. The tool analyses the image and shows its dominant colors as swatches, sorted from dark to light.

  • Choose how many colors to show: 4, 6, 8, 10 or 12. Fewer colors give broader averages; more colors pick up smaller areas.
  • Switch the format between HEX, RGB and HSL.
  • Click a swatch to copy its value, or copy the whole list at once.

One thing to understand: the extractor reports the main colors of the whole image, not the pixel under your cursor. That is ideal for questions like "what colors are in this logo" or "what is the main color of this photo". For "what is the color of this one button", narrow the image down first. Take a tight screenshot of just that area, or crop the picture with the Image Cropper, then run the extractor with the count set to 4. With only one color in the frame, the swatches will all be close to it.

Small details in a large image may not get a swatch of their own, because the tool works from a reduced sample of the picture. Cropping solves that as well.

Step 3: turn the HEX code into a name

Copy the HEX code and paste it into the Color Name Finder. It compares your color with all 148 CSS named colors and shows the closest one, along with the RGB and HSL values of your input.

Next to the name is a match label that tells you how literally to take it:

LabelMeaning
Exact MatchYour code is one of the named colors
Very CloseHard to tell apart by eye
Close MatchSame family, visibly different
ApproximateA loose description
Far OffNo named color is really similar

For example, #3B82F6 comes back as royalblue, #FF6600 as orangered and #7C3AED as blueviolet. None is exact, but each gives you a word to use in conversation or a search.

There are about 16.7 million possible HEX colors and only 148 CSS names, so most colors do not have a name of their own. Paint brands, fashion and printing systems keep their own, much larger name lists, which is why the same code can be called different things in different places. The list of CSS color names shows the full standard set.

Other ways to sample one exact pixel

When you need a single point and not an overall palette, an eyedropper is the right instrument. Several are probably already on your computer.

  • Browser color picker. Clicking the swatch in the Color Name Finder opens your browser's own color picker. In Chrome and Edge on desktop that picker includes an eyedropper button that can sample any pixel on the screen, and the name updates as soon as you pick. Whether an eyedropper is offered depends on your browser and operating system.
  • Mac. The Digital Color Meter app, found in the Utilities folder, shows the color values under the pointer.
  • Windows. Microsoft PowerToys, a free add-on from Microsoft, includes a Color Picker utility that you open with a keyboard shortcut.
  • Browser developer tools. For a color on a web page, right-click the element, choose Inspect and read the value from the styles panel. This gives the exact code the designer wrote, which is more reliable than sampling pixels.
  • Image editors. Almost every editor has an eyedropper tool that shows the HEX value of the clicked pixel.

Whichever you use, paste the resulting code into the name finder to get a name.

Why sampled colors are estimates

A HEX code taken from a screenshot of flat artwork, such as a logo or interface, is usually exact or very close. A code taken from a photograph is not, for several reasons.

  • Lighting changes everything. The same object gives different values in sunlight, shade and indoor light. Shadows and highlights on one object can differ by more than two named colors do.
  • White balance. Cameras adjust colors to make the scene look neutral, and they do not always guess correctly. A warm cast shifts every color toward yellow.
  • Compression. JPEG images blend neighboring pixels, especially at sharp edges, so a pixel near a border may be a mix of two colors. Sample from the middle of a flat area.
  • Anti-aliasing. Text and thin lines on screen are drawn with blended edge pixels. Zoom in and pick from the solid interior.
  • Screens differ. Your display, its brightness and its color settings affect how a code looks, though not the code itself.

This is why two people can disagree about a color in a photo, and why a paint or fabric match should never be made from a screen alone. Use the code as a starting point and compare physical samples.

What to do with the code

Once you have the HEX value, the rest of the color toolbox opens up. The Color Converter turns it into RGB and HSL for CSS. The Color Palette Generator finds colors that go with it. And if you plan to put text on it, the WCAG color contrast guide explains how to check that it stays readable. For background on what the code itself means, see HEX, RGB and HSL color codes explained.

Try it

Take a screenshot of the color you are curious about, drop it into the Color Palette Extractor and copy the HEX code of the matching swatch. Then paste it into the Color Name Finder to see the closest named color and how good the match is.

Tools in this guide

Frequently asked questions

How do I find the HEX code of a color in an image?

Upload the image to a palette extractor, which returns its main colors as HEX codes. For one exact spot, crop the image to that area first, or use an eyedropper: your operating system, browser developer tools and most image editors have one that reads a single pixel.

How do I find the name of a color from its HEX code?

Paste the HEX code into a color name finder. It compares your color with a list of named colors and returns the nearest one. Most colors have no exact name, so the result is the closest match, not an official title.

How do I identify a color on my screen?

Use an eyedropper. On a Mac, the built-in Digital Color Meter app shows the values under the pointer. On Windows, Microsoft PowerToys includes a Color Picker. Or take a screenshot and upload it to a tool that extracts colors from images.

Why does the same color look different in a photo?

A camera records the light that reaches it, so lighting, shadows, white balance and image compression all change the values. A red shirt photographed indoors and outdoors can produce quite different HEX codes. Treat a code sampled from a photo as an estimate.

More colors guides

JSON Formatter
Developer · Format, validate and minify JSON with syntax highlighting.
↵
Base64 Encode / Decode
Developer · Encode text to Base64 or decode Base64 back to plain text.
↵
URL Encoder / Decoder
Developer · Encode or decode URL components and query strings.
↵
Hash Generator
Developer · Generate MD5, SHA-1, SHA-256 and SHA-512 hashes.
↵
UUID Generator
Developer · Generate UUIDs v4 (random) in bulk with one click.
↵
Regex Tester
Developer · Test regular expressions against text with live match highlighting.
↵
Word Counter
Text · Count words, characters, sentences, paragraphs and reading time.
↵
Case Converter
Text · Convert text between UPPER, lower, Title, camelCase, snake_case and more.
↵
List Sorter
Text · Sort, reverse, deduplicate and shuffle lists of text.
↵
Markdown Preview
Text · Write Markdown and see a live rendered preview side by side.
↵
Percentage Calculator
Numbers · Calculate percentages, increases, decreases and what % one number is of another.
↵
Color Converter
Colors · Convert colors between HEX, RGB, HSL and HSV instantly.
↵
Snake
Arcade · Eat food, grow longer, don't hit the walls. A timeless classic.
↵
2048
Puzzle · Slide tiles and combine them to reach the legendary 2048 tile.
↵
Word Grid
Puzzle · Guess the hidden five letter word in six tries using color clues.
↵
Sudoku
Puzzle · Fill the 9x9 grid with logic. Four difficulties from easy to expert.
↵
Minesweeper
Strategy · Use number clues to clear the minefield. Classic logic, three levels.
↵
Breakout
Arcade · Smash every brick with paddle and ball. Power-ups, combos, endless levels.
↵
Typing Practice
Casual · Build your WPM and accuracy with timed drills from 30 seconds to 5 minutes. Find your weak keys.
↵
TypeRunner
Arcade · Multiplayer typing race. Race friends by link, beat computer runners, or chase your own ghost.
↵
Typing Blocks
Arcade · Type each word before its wooden block lands. Miss, and the pile climbs toward the line.
↵
Bubble Shooter
Arcade · Aim, bank shots off the walls, and pop groups of three or more bubbles.
↵
Road Rush
Arcade · Race seven rivals through traffic and punch your way to the front.
↵