How to Find Hex Code for Color: Quick & Easy Guide
Finding the hex code for a colour is a fundamental skill for anyone working in design, development, or digital art. The hexadecimal code, often prefixed with a hash symbol (#), serves as a precise numerical representation of a specific shade. Unlike subjective descriptions like "a nice blue," this code provides an unambiguous language that computers and design software interpret flawlessly. Whether you are matching a brand guideline or ensuring consistency across a website, mastering this process saves time and eliminates frustrating colour mismatches.
Using Digital Design Software
The easiest method to find a hex code is directly within your preferred graphics or design application. Modern tools are built with this functionality in mind, providing immediate feedback as you select a colour. This visual interface allows you to pinpoint the exact shade on your screen and retrieve its corresponding code in seconds.
Adobe Creative Suite
In applications like Photoshop and Illustrator, the colour information is typically displayed in the top section of the Tools panel. When you click on the foreground or background colour swatch, the colour picker window opens. Inside this window, you will see sliders and a visual spectrum, with the Hex field clearly labeled, often with a "#" symbol next to it. Simply click on the existing code to select it, and press Ctrl+C (or Cmd+C on Mac) to copy it to your clipboard for immediate use.
Figma and Online Tools
Web-based platforms like Figma operate slightly differently but offer the same result. If you select a shape or text layer, the right-hand properties panel will display the exact fill colour. You will usually see a colour chip; clicking this chip opens a more detailed palette. Within this panel, you will find a field labeled "Hex" where the code is displayed. Many tools also offer a "Copy" button next to the code, streamlining the workflow for users who need to populate CSS or other style documents quickly.
Utilizing Operating System Features
If you do not have access to design software, your standard operating system often includes a built-in colour picker. These utilities are powerful because they allow you to select a colour from anywhere on your screen, including images, websites, and videos. This is particularly useful for reverse-engineering a palette from a competitor's website or grabbing a colour from a photograph you find inspiring.
Windows Colour Picker
On Windows 10 and 11, users can invoke the Colour Picker by pressing the Windows key + Ctrl + Space. This tool creates a small floating window that magnifies the area around your cursor. You move the crosshair to the exact pixel you want, click to select it, and then click the "Copy to clipboard" button. The hex code is then ready to paste into any text field, making it a vital shortcut for developers and marketers alike.
macOS Digital Colour Meter
Apple users can access the Digital Colour Meter application, which resides in the Utilities folder within Applications. When launched, this tool displays a live magnification lens that identifies the colour under your cursor. Crucially, it provides several output modes; you can view the colour in RGB, CMYK, or Hexadecimal formats. To lock in a specific hex code, you can usually press a modifier key, such as Shift or Option, to switch the display to the exact format you require.
Browser Developer Tools
For web-related tasks, the browser's developer tools are the most direct route to a hex code. Every element on a webpage—text, buttons, or backgrounds—has a style rule attached to it. Inspecting these elements reveals the CSS properties, including the colour definitions used by the designer. This method is invaluable for ensuring your own site matches a specific visual reference or understanding how a particular site was coded.
Inspecting Elements
Right-click on any part of a webpage and select "Inspect" or "Inspect Element." This action opens the developer panel, highlighting the HTML structure. On the right side, you will see the CSS styles. Look for properties labeled color, background-color, or border-color. Next to these properties, you will see the hex code, often displayed as a clickable link. Hovering over this link usually shows a colour preview, and clicking it might allow you to adjust the shade visually in real-time before you copy the final value.
Getting precise hex values from UI or images
Analyzing live website code
| Platform | Method | Best For |
|---|---|---|
| Adobe Photoshop | Color Picker Window | High-fidelity image editing |
| Figma | Properties Panel Hex Field | Web and UI design collaboration |
| Windows PC | Colour Picker Shortcut | Quick screen color sampling |
| Mac | Digital Colour Meter | |
| Web Browser | Developer Tools Inspector |