🎨 Free Tool · No Sign-up

The Color Picker That
Actually Does Everything

Pick any color from a gradient, an image, or just type a value — and get Hex, RGB, HSL, OKLCH, and CSS instantly. Built for designers, developers, and anyone who's ever stared at a color and thought "I just need the code."

Click to copy Hex
Color Values

Color Harmony

Quick Actions

Click to upload an image or drag & drop it here

PNG, JPG, GIF, WebP — click anywhere on the image to pick a color

Your image stays on your device — nothing is uploaded to our servers.

Sample Heading Text

This is how your body text looks at this color combination. Good contrast makes reading easy and accessible for everyone, including people with low vision.

Contrast Ratio
21:1
Perfect — maximum contrast
AA Normal ✓ AA Large ✓ AAA Normal ✓ AAA Large ✓

WCAG Requirements

AA requires 4.5:1 for normal text, 3:1 for large text. AAA requires 7:1 for normal, 4.5:1 for large.

Stop 1:
#E8400A
Stop 2:
#FFD700
Direction:
background: linear-gradient(to right, #E8400A, #FFD700);

Everything a Color Picker Should Do — and More

I've used a lot of color tools over the years. Most of them do one thing: show you a gradient, you click, you get a hex code. That's fine for quick grabs, but real design work needs more. That's why we built this one differently.

Visual Gradient Picker

The main picker uses the classic SV (saturation/value) gradient panel with a separate hue slider — the same layout you know from Photoshop, Figma, and every serious design tool. No relearning required.

Image Color Sampler

Upload a photo, screenshot, or brand asset and click any pixel to extract its exact color. Your image never leaves your device — all processing happens locally in your browser. Zero privacy concerns.

Palette Generator

Generate 5-color palettes in one click. Choose from analogous, monochromatic, triadic, complementary, or random schemes. Every color comes with its hex, RGB, and HSL values ready to copy.

WCAG Contrast Checker

Paste two colors and instantly see if they pass WCAG AA or AAA accessibility standards. Includes separate checks for normal text, large text, and UI components so you can ship accessible designs confidently.

5 Output Formats

Every color you pick shows up in Hex, RGB, HSL, OKLCH, and ready-to-paste CSS simultaneously. No switching between tabs or converting manually — it's all there at once.

CSS Gradient Builder

Pick two colors, choose a direction, and get a ready-to-use CSS linear-gradient code. Quickest way to generate background gradients for buttons, hero sections, or any UI element.

Harmony Suggestions

For any color you select, see complementary, analogous, triadic, split-complementary, tetradic, and monochromatic harmonies. Click any swatch to copy it or load it into the picker.

Alpha / Opacity Control

The dedicated alpha slider lets you set transparency from 0 to 100%. Output automatically switches to rgba() and hsla() when opacity is below 100%, so you can paste straight into CSS.


How to Use the Color Picker

No tutorial needed — but here's a quick walkthrough in case you want to get the most out of every feature.

1

Click or drag on the color canvas

The main gradient panel shows the full range of saturation (left to right) and brightness (top to bottom) for whichever hue you've selected. Click anywhere on it to set your color. Drag to refine it. The white circle shows your current position.

2

Use the hue slider to change color family

The rainbow bar below the canvas is the hue slider. Drag it left or right to shift through the color spectrum — red, orange, yellow, green, cyan, blue, purple, and back to red. This changes which color family the gradient panel shows.

3

Adjust opacity with the alpha slider

The second slider controls transparency. 100% is fully opaque (solid). 0% is invisible. When you're below 100%, the output values switch to rgba() and hsla() automatically, so you can paste them straight into CSS.

4

Copy your color in any format

Every format — Hex, RGB, HSL, OKLCH, CSS — is shown in the panel on the right. Click the copy icon next to any row to grab it, or click the preview bar at the bottom to copy the hex code. A toast message confirms the copy.

5

Type a value directly to start from a known color

Already know your color? Type a hex code like #3498db directly into the Hex field and press Enter. The picker updates to show that color and gives you all the other formats instantly.

6

Explore harmonies and quick actions

Change the harmony dropdown to see color combinations that work well with your pick. Use Lighten, Darken, and Saturate buttons to make quick adjustments. Hit Random to discover unexpected color starting points.


Understanding Color Formats: A Practical Guide

If you've worked on any web project, you've probably copied a hex code without thinking much about what it actually means. That's fine — hex codes work great and most tools accept them. But knowing what's behind the code gives you real control over your colors, especially when you need to make adjustments programmatically or explain a color decision to a client.

Hex codes: why six characters?

A hex color like #E8400A is really three separate numbers written back-to-back: E8 (red), 40 (green), and 0A (blue). Each pair is a hexadecimal number — base 16 instead of base 10 — so it goes from 00 (zero) to FF (255). That gives you 256 possible values per channel and 16.7 million combinations total. The # at the start is just a flag telling the browser "this is a hex color value."

Short hex codes like #F60 are shorthand for #FF6600 — each character gets doubled. You'll see this in older CSS. Modern code usually uses the full six-character version for clarity.

Quick tip: If your hex code starts with #FF, your red channel is maxed out. If it ends with FF, blue is maxed. White is #FFFFFF (all channels at 255), black is #000000 (all channels at 0). Once that clicks, reading hex codes gets a lot easier.

RGB: the same thing, just more readable

rgb(232, 64, 10) says the same thing as #E8400A — 232 red, 64 green, 10 blue. The decimal format is more intuitive for humans. When you need to add transparency, you use rgba(232, 64, 10, 0.5) where the fourth value is opacity from 0 to 1. This is useful for overlays, shadows, and any element that needs to show through.

One practical advantage of RGB over hex: it's much easier to adjust. If a color looks too yellow and you want to reduce the green, you can just lower the G value. With hex you'd need to convert first.

HSL: color the way your brain thinks about it

HSL is my personal favourite format for writing CSS from scratch. hsl(16, 92%, 48%) breaks down as: hue 16° (an orange-red on the color wheel), saturation 92% (very vivid), lightness 48% (close to middle brightness). Want a lighter version? Change 48% to 65%. Want a softer, more muted tone? Drop the saturation to 50%. These tweaks are intuitive in a way that hex never is.

HSL also makes color scales easy to build in CSS. A consistent set of grays with hsl(0, 0%, 10%) through hsl(0, 0%, 95%) is much more maintainable than a list of random hex codes.

OKLCH: the new standard worth knowing

OKLCH is newer and you won't need it for most projects right now, but it's worth understanding because it solves a real problem: colors that look equally bright to your eyes don't always have equal lightness values in RGB or HSL. OKLCH uses a perceptually uniform model — if you change the lightness value, the brightness change you see matches what the number says. Design systems at companies like Radix and Tailwind are starting to build their palettes in OKLCH. Our picker shows the OKLCH value for reference so you're ready when the ecosystem catches up.

What Makes a Good Color Picker?

After using dozens of color tools, I've noticed what separates the ones people keep bookmarked from the ones they try once and forget. It's not complexity — it's usefulness per interaction.

The best tools get you from "I need a color" to "I have the code I need" in as few steps as possible. That means: the picker opens already doing something useful (not blank), every value is visible without extra clicks, and copying is one action — not three. It also means the tool handles real use cases: picking from an image, checking accessibility, building a palette — not just the single-color-in-a-vacuum scenario.


Who Uses a Color Picker — and How

Color pickers aren't just for web designers. Here's who reaches for one and what they're actually doing with it.

🎨

UI/UX Designers

Matching brand colors to pixel-perfect specs, building accessible color systems, and testing whether button and background combos pass WCAG before handing designs to developers.

💻

Frontend Developers

Translating design tokens into CSS, converting between formats when libraries expect different inputs, and quickly checking what a hex code looks like before hardcoding it.

📸

Photographers & Editors

Extracting dominant colors from photos to build cohesive color stories, matching print and screen colors, and creating mood boards from reference images.

🏪

Small Business Owners

Finding the exact hex code for their logo color to use consistently across their website, social media graphics, and print materials — without needing to open Photoshop.

✏️

Students & Learners

Understanding how RGB and hex values work, experimenting with color theory through the harmony tool, and completing design or web development assignments.

🎮

Game & App Developers

Building UI themes, generating gradient backgrounds, and ensuring color contrast meets accessibility requirements for mobile interfaces used in varying lighting conditions.


Color Picker Tips From Real Practice

Things worth knowing that most color picker guides don't mention.

Start with lightness, not hue

When building a UI color palette, most designers pick hues first and adjust later. The opposite works better: decide your lightness scale first, then apply hues. This makes your palette feel systematic rather than arbitrary.

Test your colors on a real display

Screens vary wildly. A color that looks perfect on your MacBook Pro's P3 display can look washed out or oversaturated on a standard sRGB monitor. Always check your final palette on at least one other screen before shipping.

When in doubt, use HSL in your CSS

Hex is fine for static colors. But if you're setting colors in CSS custom properties, HSL is far easier to adjust and reason about. hsl(220, 90%, 56%) is immediately legible in a way #1a6efc just isn't.

Check contrast before you fall in love

It's easy to pick a gorgeous color combination and only discover at the end that it fails WCAG AA for body text. Run it through the Contrast Checker tab early.

  • AA normal text: 4.5:1 minimum
  • AA large text (18px+): 3:1 minimum
  • AAA normal text: 7:1 minimum
  • UI components: 3:1 minimum

The color wheel harmony types, explained plainly

Complementary colors sit opposite each other — high contrast, great for CTAs. Analogous colors are neighbors — cohesive, good for backgrounds. Triadic uses three evenly spaced colors — vibrant but harder to balance. Monochromatic is one hue at different lightness levels — safe and elegant.

Type a hex code to skip the picking step

Got a hex from a Figma file or brand guide? Just type it directly into the Hex field and press Enter. The picker will jump to that color and give you all the other formats — RGB, HSL, OKLCH — right away.


Color Format Comparison

Which format should you actually use? Here's a quick reference.

FormatExampleSupports AlphaHuman ReadableCSS SupportBest For
Hex#E8400A✓ (#RRGGBBAA)✗ Not intuitive✓ UniversalDefault for HTML/CSS
RGBrgb(232,64,10)✓ rgba()Moderate✓ UniversalTransparency, JS canvas
HSLhsl(16,92%,48%)✓ hsla()✓ Very intuitive✓ UniversalCSS variables, design systems
OKLCHoklch(65% .21 33)ModerateModern browsers onlyPerceptual color scales
CSS Nametomato✓ Very readable✓ UniversalPrototyping, quick tests

Frequently Asked Questions

Real questions from real users — answered without the fluff.

A color picker is an interactive tool that lets you visually select any color and get its code in a format you can use in design software or code. Instead of guessing hex values or converting between formats by hand, you point at a color on a gradient and the tool does the math. Our color picker goes further by adding image sampling, palette generation, contrast checking, and gradient building in the same place.
Click the "Image Picker" tab in the tool above, then either click the upload zone or drag an image file onto it. Once the image appears, click anywhere on it — the tool samples the pixel at that exact point and shows you its Hex, RGB, and HSL values. Everything stays local in your browser; the image is never sent to a server.
They're all ways to describe the same color, just in different notations. Hex is the most compact (6 characters) and universally accepted. RGB spells out red, green, and blue channels as numbers from 0–255, which is useful when you need transparency (rgba). HSL describes hue as a degree on the color wheel plus saturation and lightness as percentages — the most intuitive format for making manual adjustments. Our picker shows all three simultaneously so you always have whichever one you need.
Yes. The picker supports touch events so you can drag across the gradient panel and hue slider on any smartphone or tablet. The layout also adapts for smaller screens — the values panel moves below the canvas on narrow viewports. Everything works, including image upload from your phone's camera roll.
OKLCH is a newer color space designed to match how human eyes perceive color differences. In regular RGB or HSL, two colors might have the same "lightness" value but look noticeably different in brightness to your eye. OKLCH fixes this with perceptually uniform math. You probably don't need it for simple projects, but if you're building a large design system and want the lightness to feel consistent across hues, OKLCH is worth exploring.
Click the "Contrast Checker" tab. Enter your text color and background color — either by typing hex values or using the color input. The tool calculates the contrast ratio and shows whether it passes WCAG AA and AAA for both normal text (≥4.5:1 for AA) and large text (≥3:1 for AA).
Yes — that's exactly what the Palette Generator tab does. Pick your base color in the main picker, switch to the Palette Generator tab, choose a harmony type (analogous, monochromatic, triadic, etc.), and click Generate. You'll get a 5-color palette with hex codes for each swatch. Click "Copy All" to get every color at once.
Yes, genuinely free. No account, no daily limit, no watermarks, no "pro tier" that locks features. You can use it for personal projects, freelance client work, or production commercial applications without restriction. We keep the lights on through display advertising, not subscriptions.
Yes. The Gradient Builder tab generates standard CSS like background: linear-gradient(to right, #E8400A, #FFD700); which works in any modern browser without any prefixes needed. Click the copy button next to the code and paste it directly into your stylesheet.

@ HtmlColor.Codes· All tools free · Built for designers & developers worldwide
✓ Copied!