Free guideThe newsletter. Real UI fixes by email, and a free 35-page guide to AI design skills.
Ship Better UI

, 1 minute 40 seconds

How should you name colours in a design system?

The rule

Name each colour by the job it does, not by how it looks: one grey ramp in 6 steps, one accent only for what you can click, status colours that keep their words, and tokens named by job, like --text-primary.

Try it

Apply the fix

Prompt for your AI coding tool

Paste it into Claude Code, Cursor or any AI coding tool, then share the page you want fixed.

Review the colours in the interface I share. Name each colour by the job it does, not by how it looks. Fix what fails, and change nothing else.

1. Neutral ramp: replace greys picked from different families with one grey in 6 even steps, from background to text.
2. One accent with one job: use the one bright colour only on what you can click, like buttons and links. A status badge never borrows it.
3. Status colours: green for ready, amber for building, grey for queued. Each badge keeps its word, so it reads without colour.
4. Names by job: name each colour token by what it does, like --surface, --text-primary, --text-muted, --action, --status-warning and --status-success, not by how it looks, like orange-500 or zinc-400. In light mode the names stay; only the colours behind them change.

Keep the content, the features and the layout. When you are done, list each old colour name and the token that replaced it.

More prompts like this in the free guide 

The problem

The deploys panel in the video names its colours by hue, by how they look: orange-500, green-500 and four greys from four families. Orange has two jobs. On the Deploy button and the "View all logs" link, it means click me. On the Building badge, it means still running, so people tap the badge, and nothing happens.

The fix

Same panel, same words. Name each colour by the job it does, in four fixes.

  1. One neutral ramp. One grey in six even steps, from background to text. Four greys become one.
  2. One accent with one job. The one bright colour marks only what you can click. The badge gives orange back.
  3. Status colours. Green for ready, amber for building, grey for queued. Each badge keeps its word.
  4. Names by job. A token is a named colour in your code, like --text-primary or --action.

Why it works

A name by hue says how a colour looks, not where it belongs, so nothing stops orange from taking a second job. A name by job gives each colour one meaning: --action means click me, and a badge has no reason to borrow it. Each badge keeps its word, so it reads without colour. Switch to light mode and the names stay; only the colours behind them change. Named by hue, orange did two jobs. Named by job, each colour does one.

How to apply it

List the colours in your code and ask what job each one does. Fold the greys into one ramp of six steps, keep the accent for what you can click, and give each status its own colour and word. Then name each token after its job, not its hue.

Free guide · 35 pages

Get fixes like this by email

Join the newsletter and get the 35-page guide to AI design skills: the skills, the order to use them in, and prompts to copy.

Watch it on

More on colour

All 5 lessons on colour