Colour palette generator
Build a five-colour palette from colour-wheel rules, lock the ones you like, check text contrast, and export as CSS, Tailwind or JSON.
:root { --color-primary: #26abc0; --color-accent: #4e9bdf; --color-support: #242e99; --color-soft: #d7f4ec; --color-deep: #21452a;}Colours that sit next to each other share undertones, so they feel calm and natural together: like a sunset or a forest.
Each colour as a background with white or black text, scored against WCAG. 4.5 : 1 is the minimum for body text, 3 : 1 for large headings.
HSL was designed in 1978 to be cheap to compute on frame buffers, not to match perception. Every swatch below has identical HSL saturation and lightness. The bars show each colour’s OKLab lightness, a model fitted to how bright colours actually look, computed live from the hex value.
Nine shades from 50 to 800. The top row steps HSL lightness evenly; the bottom row steps OKLCH lightness evenly and keeps chroma inside the sRGB gamut. Check how evenly the measured L moves and where white text first passes 4.5 : 1.
:root { --primary-50: oklch(97.0% 0.026 211); --primary-100: oklch(88.0% 0.106 211); --primary-200: oklch(79.0% 0.137 211); --primary-300: oklch(70.0% 0.121 211); --primary-400: oklch(61.0% 0.106 211); --primary-500: oklch(52.0% 0.090 211); --primary-600: oklch(43.0% 0.075 211); --primary-700: oklch(34.0% 0.059 211); --primary-800: oklch(25.0% 0.043 211);}For the hue set above, each column is the highest OKLCH chroma that still fits in sRGB (solid) and Display P3 (tall, light). Limits are found by bisection on the real conversion matrices. The dashed line is the chroma you asked the scale for; wherever it rises above a column, that shade was clipped.
Simulated with the Machado, Oliveira and Fernandes (2009) matrices at full severity, applied in linear RGB. Below, every pair of colours is scored by OKLab distance (ΔE OK) under each simulation. About 0.02 is a just-noticeable difference; under 0.06 two colours are hard to tell apart as UI elements, so don’t let them carry meaning on colour alone.
Each value below is converted from #26abc0 with the CSS Color 4 matrices (lab and lch use D50, as the spec requires). The swatch is painted by your browser from that exact string, and the last column asks CSS.supports() whether it parses.
#26abc0CSS1; 4/8-digit forms in Color 4check_circleyesrgb(38 171 192)CSS1; space syntax in Color 4check_circleyeshsl(188 67% 45%)CSS Color 3 (2011)check_circleyeshwb(188 15% 25%)CSS Color 4check_circleyeslab(64.0 -30.1 -21.3)CSS Color 4 (D50)check_circleyeslch(64.0 36.8 215.2)CSS Color 4 (D50)check_circleyesoklab(0.683 -0.095 -0.057)CSS Color 4check_circleyesoklch(68.3% 0.111 211.2)CSS Color 4check_circleyescolor(display-p3 0.3287 0.6609 0.7418)CSS Color 4check_circleyescolor-mix(in oklch, #26abc0 70%, white)CSS Color 5check_circleyesoklch(from #26abc0 calc(l + 0.1) c h)CSS Color 5check_circleyeslight-dark(#26abc0, #d7f4ec)CSS Color 5check_circleyesPick, check and pull colours from anywhere.