Chart colour palette generator
Start from your brand colour. The generator picks colours that stay apart for most readers, checks them against three kinds of colour-blindness and greyscale, and tells you which pair is closest.
#3346ff6.1:1#44250013.9:1#949a1b3.0:1#7e097d9.4:1#d33c8b4.4:1#6e0b4411.7:1
Typical colour vision
Deuteranopia (green-blind)
Protanopia (red-blind)
Tritanopia (blue-blind)
Greyscale (printed in black and white)
- ✓ Typical colour vision: closest pair 4 and 6, 10 apart
- ⚠ Deuteranopia (green-blind): closest pair 2 and 6, 9 apart (hard to tell apart; label them directly)
- ✓ Protanopia (red-blind): closest pair 2 and 6, 11 apart
- ⚠ Tritanopia (blue-blind): closest pair 4 and 6, 6 apart (hard to tell apart; label them directly)
- ⚠ Greyscale (printed in black and white): closest pair 2 and 6, 5 apart (hard to tell apart; label them directly)
Hex codes
#3346ff, #442500, #949a1b, #7e097d, #d33c8b, #6e0b44CSS custom properties
--chart-1: #3346ff;
--chart-2: #442500;
--chart-3: #949a1b;
--chart-4: #7e097d;
--chart-5: #d33c8b;
--chart-6: #6e0b44;JSON
["#3346ff","#442500","#949a1b","#7e097d","#d33c8b","#6e0b44"]How the palette is picked
Your colour comes first. Each next colour is the one that stays furthest from all the colours already picked, judged three ways: with typical colour vision, with deuteranopia and with protanopia (the two common kinds of red-green colour-blindness). Greyscale counts at half weight, for anyone who prints in black and white. Distances are measured in OKLab, a colour space in which equal steps look about equal to the eye.
Under the swatches, each row names the pair of colours that comes out closest for that kind of vision. Where two colours end up close, keep them apart in the chart, or label the lines and bars directly so colour is not the only clue.
For thin lines and small marks, WCAG asks for at least 3:1 contrast against the background. Leave the 3:1 option on for line charts. Turn it off for big areas, such as bars and maps, where paler colours are fine.
More in colour-blind safe chart colours.
Questions
- What makes a good chart colour palette?
- Colours that stay easy to tell apart for everyone, enough contrast with the background for thin lines and small marks (WCAG suggests at least 3:1 for graphics), and no more colours than the chart needs.
- How is colour-blindness checked?
- Each colour is run through a standard simulation (Machado, Oliveira and Fernandes, 2009) of the three main kinds of colour-blindness, and through greyscale. The tool then measures how far apart the closest pair still is. A simulation is an approximation, and real vision varies.
- Categorical, sequential or diverging?
- Categorical palettes are for separate groups. Sequential palettes run light to dark, for amounts. Diverging palettes run from one colour through a neutral middle to another, for values above and below a midpoint.
- How many colours can a chart use?
- Keep it to about six or fewer for separate groups. Past that, colours get hard to tell apart and to match to a legend, so label lines directly or split the chart into small multiples.