Accessible color palette generator
Give it one brand colour. Get a full scale, and the exact steps that are safe for buttons, links, borders and dark mode. Free, instant, and nothing leaves your browser.
Your brand colour
Try an example
What your colour can do
#4f46e5
Sits at step 600 of your scale
- ✓ PassWhite text on your colour: 6.29:1. Fine for buttons and banners.
- ✕ FailBlack text on your colour: 3.34:1. Dark text is too faint here.
Your colour scale
Eleven steps from very light to very dark, evenly spaced to the eye. Each tile shows the text colour that reads best on it.
50
#f4f6ff
Black 19.47
100
#e8ecff
Black 17.87
200
#d1d8ff
Black 14.98
300
#b5bfff
Black 11.86
400
#929eff
Black 8.56
500
#727aff
Black 5.94
600 (your colour)
#4f46e5
White 6.29
700
#463ccf
White 7.48
800
#342aa6
White 10.36
900
#24197c
White 13.95
950
#130850
White 17.82
See the contrast numbers for every step
| Step | Colour | On white | On dark (#111111) |
|---|---|---|---|
| 50 | #f4f6ff | 1.08:1 ✕ | 17.51:1 ✓ AA |
| 100 | #e8ecff | 1.17:1 ✕ | 16.07:1 ✓ AA |
| 200 | #d1d8ff | 1.4:1 ✕ | 13.47:1 ✓ AA |
| 300 | #b5bfff | 1.77:1 ✕ | 10.67:1 ✓ AA |
| 400 | #929eff | 2.45:1 ✕ | 7.69:1 ✓ AA |
| 500 | #727aff | 3.53:1 large text only | 5.34:1 ✓ AA |
| 600 (yours) | #4f46e5 | 6.29:1 ✓ AA | 3:1 large text only |
| 700 | #463ccf | 7.48:1 ✓ AA | 2.52:1 ✕ |
| 800 | #342aa6 | 10.36:1 ✓ AA | 1.82:1 ✕ |
| 900 | #24197c | 13.95:1 ✓ AA | 1.35:1 ✕ |
| 950 | #130850 | 17.82:1 ✓ AA | 1.06:1 ✕ |
Safe pairs to use
Picked from your scale so each one passes WCAG, with the ratio shown.
- Book now
Button with white text
The lightest step that still gives white text 4.5:1.
White on 6006.29:1 ✓ Pass
- Read the details
Links and text on white
Coloured text on a white page needs 4.5:1 too.
600 on white6.29:1 ✓ Pass
- Read the details
Links on a dark background
For dark mode or dark sections. The darkest step that still reads on near-black.
500 on dark5.34:1 ✓ Pass
- Input with a border
Borders, icons and focus rings
Parts of controls need 3:1 against what they sit on (WCAG 1.4.11).
500 on white3.53:1 ✓ Pass
- Callout text
Text on a light tint
Callouts and badges: a very light background with a dark step for the text.
950 on 5016.53:1 ✓ Pass
Take it with you
:root {
--brand-50: #f4f6ff;
--brand-100: #e8ecff;
--brand-200: #d1d8ff;
--brand-300: #b5bfff;
--brand-400: #929eff;
--brand-500: #727aff;
--brand-600: #4f46e5;
--brand-700: #463ccf;
--brand-800: #342aa6;
--brand-900: #24197c;
--brand-950: #130850;
}
Why brand colours fail on the web
Brand colours are chosen to look good on a logo, not to carry small text. Orange, yellow, green, pink and light blue are all popular, and all of them are too light for white text at normal sizes. The usual result is a button that looks fine to the designer and is hard to read for everyone else.
The fix is rarely a new brand colour. It is a scale: keep your colour for logos and large shapes, and use a darker step from the same hue for text and buttons. This tool builds that scale, checks every step, and tells you which one to reach for.
Shades for popular colours
Want to see how a common colour behaves before you start? Pick one below to see its scale, whether it works with white text, and the closest step that does.
- Blue#2563eb
- Sky blue#0ea5e9
- Indigo#4f46e5
- Purple#7c3aed
- Pink#ec4899
- Red#dc2626
- Orange#f97316
- Amber#f59e0b
- Yellow#eab308
- Lime#84cc16
- Green#16a34a
- Emerald#10b981
- Teal#0d9488
- Cyan#06b6d4
- Navy#1e3a8a
- Burgundy#7f1d1d
- Brown#92400e
- Grey#6b7280
Questions people ask
What is an accessible colour palette?
It is a set of colours where the pairs you actually use together, such as text on a background or white text on a button, have enough contrast for people to read them. WCAG asks for at least 4.5:1 for normal text and 3:1 for large text and for parts of controls such as borders and icons.
How does the generator build the scale?
It converts your colour into OKLCH, a colour space where equal steps look equally different to the eye, then makes eleven steps from very light (50) to very dark (950) with the same hue. Your exact colour is placed at the step closest to its lightness, so your brand colour is always in the scale unchanged.
My brand colour fails with white text. Do I have to change it?
No. Keep it for logos, large shapes and decoration, where the rules are looser. For buttons and text, use a darker step from the same scale. It keeps your hue, so the design still feels like your brand, and the tool shows you which step to use.
Which steps should I use for what?
As a starting point, use the light steps (50 to 200) for backgrounds and tints, the middle steps (300 to 500) for decoration and large shapes, and the dark steps (600 to 900) for text, links and buttons with white text. The "Safe pairs" section picks the exact steps for your colour.
Does it help with dark mode?
Yes. It shows the lightest-passing and darkest-passing steps on both white and a near-black background, so you can choose a lighter step for text on dark sections.
Can I use the code in my project?
Yes. Copy the scale as CSS variables, Tailwind v4 or v3 config, or JSON. It is yours to use however you like.
Is my colour sent anywhere?
No. Everything runs in your browser. There is no sign-up and nothing is stored.
Is this a replacement for a full accessibility check?
No. Colour is only one part of accessibility. Passing contrast is a good start, but you also need to check things like focus indicators, images, forms and keyboard use. A free scan of your site finds many of those.
Need to test two specific colours instead? Use the contrast checker.
Is your live site using these colours well?
A free scan checks every colour pair on your page against WCAG 2.2 and shows what to fix.