css - How to determine the color html code of a region in an image - Stack Overflow
Tip: How to get color values using Photos
How do I find out the html color code of a color in my image? โ Ribbet Blog
Online Color Picker From Image
How do I find the exact color code of an image?
Is Image Color Picker free to use?
What is a HEX color code?
Videos
If I understand you correctly you wanted to get the color of what you see on your screen. Then perform these steps.
- Take a screenshot of what you see and paste it in mspaint.
- Then use colour picker from tools menu and click on the place for which you wanted to know the colour.
- Then under color menu use edit Colors option.
- There in the edit Colors menu in the right side you will get the right color coordinates.
Now use editors like Visual Studio Code to get what you want.
These are the steps that worked for me:
- open the image in gimp
- Make sure the toolbox dialog is visible. If it is not use "Windows -> new Toolbox".
- Make sure The colors dialog is visible. If it is not "Windows -> Dockable Dialogs -> Coulours"
- Select the eye drop icon in the toolbox dialog (when you hover it it will show this text: Color Picker Tool: Set Coulours from image pixels).
- click on the area of the image that you want to get the color code (the code will automatically show at the bottom of the coulors dialog).
Just shared this as a comment elsewhere, and realized it could be helpful in general here.
-
Take a screenshot, if necessary.
-
In Photos app, select the photo.
-
Tap Edit.
-
Tap the Markup symbol.
-
Tap the color circle.
-
Tap the color dropper icon.
-
Drag color picker circle over a color.
-
Release picker when it is same color.
-
If necessary, tap Sliders tab.
-
View RGB and hex color values.
12/15/21 Edit:
Added the following information:
The default displayed hex code is for the Display P3 color space. Tapping the blue phrase (default Display P3 Hex Color #) pops up a menu with an option to show sRGB Hex Color #.
In Windows, there is an easier way that doesn't need any software.
- Capture the screen in an image file (use something like the Snipping Tool to grab the desired area)
- Open the file with MS Paint
- Use Paint's pick color and pick the color
- Press "Edit Colors" button
- You have the RGB values!
Newer alternative
See Richie Bendall's answer about PowerToys' Color Picker. PowerToys includes multiple useful utilities as well!
Original suggestion
Instant Eyedropper is exactly what you were searching for.
How it works
- Move the mouse pointer to the Instant Eyedropper icon in the system tray.
- Press and hold the left mouse button and move the mouse pointer to the pixel whose color you want to identify.
- Release the mouse button.
That's it. The clipboard now contains the color code - in HTML format (or any other format that you have previously specified). It can be pasted and used in any text or HTML editor or the Color Picker tool of Photoshop.
It comes with all the options that I personally wanted of such tool.
- Clipboard color pattern (Hex, and others)
- Startup on system tray
- No overhead or ads and it's free.

Works on windows XP, vista, 7, 8, 10 and probably beyond that.
Clarification on values returned by the HSB option
Note that HSB format gives standard values, which are:
- Hue: 0-359 degrees
- Saturation: 0-100%
- Brightness: 0-100%
Some tools like Paint on windows will give slightly different values:
- Hue: 0-239
- Saturation: 0-240
- Luminance: 0-240
The reasoning is explained on the windows blog.
The theoretical range for Hue is an angle, normalized to be greater than or equal to 0ยฐ and strictly less than 360ยฐ. The upper value of the range is not reached because Hue is cyclical, so a value of 360ยฐ is equivalent to 0ยฐ. On the other hand, Saturation and Luminance are floating point values between 0.0 and 1.0 (inclusive).
In Windows, the Hue, Saturation, and Luminance ranges are rescaled so that they go from 0 to 240. Hue is endpoint-exclusive (because 360ยฐ = 0ยฐ) whereas Saturation and Luminance are endpoint-inclusive (because 1.0 is achievable).
If you want to use Eyedropper on windows with a tool like Paint, you can do the math with the ratios explained above, or just use the RGB value whenever possible.
I found this tool years ago and still use it from time to time. I'm not its developer nor am I affiliated with the developer. If it doesn't fit your specific needs or if you'd like to see a new feature, contact the dev himself on his website.

