Generate colour palettes from one base colour, with tints and shades, contrast and colour-blindness checks, and CSS, Tailwind or JSON export.
Initializing in your browser…
Extract the main colours of a photo as a palette with hex, RGB and HSL codes and their share of the picture, and export it as CSS, SCSS, Tailwind, JSON, CSV or GIMP.
Convert colours between HEX, RGB, HSL, OKLCH, Lab and five more formats, check WCAG contrast, and preview colour-blind vision.
Hash text or files with MD5, SHA-1, SHA-256 or SHA-512 as you type, create HMAC signatures, and check a download against its published digest.
A dashboard needs three accent colours that work with the brand red #c0392b.
Base colour and scheme
#c0392b, triadic
Palette and checks
OKLCH #c0392b #00873b #4964d3 4.4 L* apart, even
HSL #c0392b #2bc039 #392bc0 38.0 L* apart, uneven
OKLCH palette:
best contrast between swatches 1.17:1
deuteranopia: closest pair 9.2 dE2000, hard to tell apart
achromatopsia: closest pair 1.2 dE2000, identical
:root {
--brand-100: #c0392b;
--brand-200: #00873b;
--brand-300: #4964d3;
}Rotating the hue by 120 and 240 degrees in OKLCH keeps all three colours within 4.4 points of perceived lightness, so they read as equal partners. The same rotation in HSL produces a much brighter green and a darker blue, 38 points apart, because HSL lightness does not match what the eye sees. The price of even lightness is shown straight away: no two swatches get anywhere near a readable contrast, and to a reader with deuteranopia the red and the green are hard to tell apart. So the palette works as chart or badge colours with labels, while text should use the 50 to 950 ramp.
Pick one base colour and get a matching palette, complementary, analogous, triadic, split complementary, square, tetradic or monochromatic, plus a full set of tints and shades from 50 to 950. Every palette is checked for contrast and for how it looks to colour-blind readers, and can be copied or downloaded as HEX, CSS variables, SCSS, Tailwind or JSON.
A colour harmony is a set of hues at fixed angles around the colour wheel: opposite for complementary, a third of the way round for triadic, neighbours for analogous, and so on. Choose a base colour by typing a hex value, using the colour picker or pressing Random, then choose a scheme, and the palette updates at once. Click any swatch to copy its hex code, or copy them all.
The tool rotates hue in OKLCH by default, a modern colour space built so that equal numbers look equally light. That keeps every swatch at the same perceived lightness, so the colours differ only in hue, which is usually what a designer wants from a harmony. The traditional way, rotating hue in HSL, is one tap away. HSL's lightness is not how light a colour looks: pure yellow and pure blue share 50 percent lightness in HSL but look completely different in brightness. Under the palette the tool reports how far apart the swatches are in perceived lightness (CIE L*) in the chosen space and in the other one, so you can see the difference. When a rotated colour falls outside the range a screen can show, its chroma is reduced until it fits while its lightness and hue are kept, and the swatch says it was toned down.
Equal lightness has a cost, and the tool shows it. Colours of equal lightness have almost no contrast with each other, so a harmony is for accents, not for text on a background. The contrast table lists the WCAG ratio for every pair and against white and black. The tints and shades ramp from 50 to 950 is spaced evenly in perceived lightness, like the scales in Tailwind and most design systems, and is where readable text and background pairs come from.
Colour vision deficiency affects about one man in twelve. The View as control repaints the palette as it appears with protanopia, deuteranopia, tritanopia and achromatopsia, and the tool warns when two swatches would look nearly the same to some readers. Hues that only differ in hue are the most likely to collide, which is why a status palette needs labels, icons or a lightness difference as well as colour.
Exports cover the common destinations: plain HEX, RGB, HSL or OKLCH lists, a CSS :root block with custom properties, SCSS variables, a Tailwind colors object and JSON with lightness and chroma for each swatch. Copy the text or download it as a file. The share link keeps the base colour, scheme, colour space and export format, and everything runs in your browser.
Begin from the brand colour, take a complementary or split complementary accent, and use the 50 to 950 ramp for backgrounds, borders and text.
Generate distinct series colours, then check them under deuteranopia so lines and bars stay tellable apart for every reader.
Export a :root block or a Tailwind colors object and paste it straight into your stylesheet or config.
Switch between OKLCH and HSL to see why an HSL triadic palette looks unbalanced and an OKLCH one does not.
OKLCH keeps perceived lightness constant, so every swatch looks equally light and only the hue changes. HSL keeps its own lightness number constant, which does not match what the eye sees, so an HSL palette can mix a very bright yellow with a dark blue. The tool shows the lightness spread for both.
Because a harmony at one lightness has almost no contrast between its colours. Text needs a big lightness difference: use the 50 to 950 ramp, for example the 900 step on the 50 step, for text and backgrounds, and keep the harmony for accents.
Rotating a saturated colour can land on a hue that a normal screen cannot show at that intensity. The tool lowers its chroma until it fits the sRGB range, keeping the hue and lightness, as CSS Color 4 does.
Use View as to preview it, read the warning about pairs that collide, and make sure important differences also show up as a change in lightness, a label or an icon. Triadic and complementary pairs of red and green are the usual problem.
CSS for plain stylesheets, SCSS for Sass projects, Tailwind for a tailwind config, and JSON when another tool or script needs the values. The HEX list is the simplest to paste into design software.
Conversions run on your device in JavaScript. The values you enter are never sent over the network.