Colour
Colour shows what’s official, what people can act on and what needs their attention. Always use the colour roles, never raw values, so every site stays accessible and can change theme.
Updated
How colour works
NDS colours come in three layers. Designers and developers only use the top one, the colour roles.
-
1 · Primitives
The raw palettes: green, yellow, red, blue and neutral, from 50 to 950. Never used directly.
color/green/600
-
2 · Brand
A scale from 50 to 950 that follows the site’s brand: Naija Green, Naija Red or Naija Yellow.
Brand 600
-
3 · Colour roles
Named for what they do: text, surface, border, action and status. These are the ones you use.
action/primary/default
Every colour role has a Light and a Dark value. Use the role and the theme takes care of itself. Values and contrast on this page are for the Light theme. The same green appears at every layer.
Naija colours
The national colours. They’re static, so they don’t change with theme or brand. Use them for brand moments and the coat of arms, not for text.
-
Naija Green
#007345
5.8:1 with white text. Can carry white text and icons.
-
Naija Red
#D32F2F
4.9:1 with white text. Can carry white text at any size.
-
Naija Yellow
#CA8A04
2.9:1 with white text. Use dark text on it (6.1:1).
Static also includes white (#FDFDFD) and black (#171717), for things that must look the same in every theme, like the coat of arms.
Text
Text colours, with their contrast on the page background (surface/canvas). Body text needs at least 4.5:1. Values shown are for the Light theme; every token also passes in Dark.
| Token | Value | Use | Contrast |
|---|---|---|---|
| text/primary | #171717 | Headings, body text and icons. | Passes: 17.6:1 |
| text/secondary | #5C5C5C | Descriptions, hints and supporting text. | Passes: 6.6:1 |
| text/muted | #5C5C5C | Captions, timestamps and placeholders. | Passes: 6.6:1 |
| text/disabled | #A3A3A3 | Text on disabled controls only. | 2.5:1 · exempt |
| text/white | #FDFDFD | Text and icons on solid fills, like a primary button. | Passes: 5.8:1 on green |
Surfaces
Backgrounds for pages, panels and sections.
| Token | Value | Use |
|---|---|---|
| surface/canvas | #FDFDFD | The page background. |
| surface/subtle | #FAFAFA | Panels, and hover or selected table rows. |
| surface/muted | #F5F5F5 | Table header rows, and sections that sit next to each other. |
| surface/container | #EBEBEB | Containers that need a defined edge without a border. |
Borders
Pick a border by what the line does. Lines inside something are lightest, outer edges are darker, and control outlines must reach 3:1.
| Token | Value | Use | Contrast |
|---|---|---|---|
| border/divider | #EBEBEB | Lines inside components: table rows, list items and menu sections. | 1.2:1 · decorative |
| border/subtle | #EBEBEB | Outlines of disabled controls, and quiet containers. | 1.2:1 · decorative |
| border/default | #D1D1D1 | The outer edge of cards, tables and tiles. | 1.5:1 · decorative |
| border/strong | #7B7B7B | Outlines of form fields and other controls. | Passes: 4.2:1 |
| border/dark | #292929 | High-contrast edges, and control outlines that need extra emphasis. | Passes: 14.3:1 |
| border/focus | #008751 | Keyboard focus ring. Follows the brand mode; 6.0:1 in Dark. | Passes: 4.5:1 |
Actions
Colours for buttons and other things people press. Each swatch is the token action/role/state, for example action/primary/hover. Use the component, not the colours, wherever you can.
| Role | Default | Hover | Pressed | Disabled | Text | Border | Subtle |
|---|---|---|---|---|---|---|---|
| Primary | #007345 | #005C37 | #00452A | #EBEBEB | #FDFDFD | #007345 | #E6F5EE |
| Secondary | #292929 | #333333 | #1C1C1C | #EBEBEB | #FDFDFD | #333333 | #F5F5F5 |
| Tertiary | #FAFAFA | #EBEBEB | #D1D1D1 | #EBEBEB | #1C1C1C | #EBEBEB | #F5F5F5 |
Status
For messages that tell people something went well, needs attention, is information or went wrong. Always pair the colour with an icon and words.
| Status | Surface (solid) | Background (panel) | Border |
|---|---|---|---|
| Success | #007345 | #E6F5EE | #99D5B8 |
| Warning | #A16207 | #FFFBEB | #FEF08A |
| Info | #235BE6 | #F4F7FE | #D5E1FA |
| Error | #D32F2F | #FFF5F5 | #FDD8D8 |
Warning surface is Naija Yellow. Put dark text on it (3.6:1); white text is only 4.8:1.
Brand scale
The brand scale follows the site’s brand mode: Naija Green (default), Naija Red or Naija Yellow. It’s applied through the action roles, so you rarely use it directly.
- 50 , #E6F5EE
- 100 , #C2E7D5
- 200 , #99D5B9
- 300 , #6FBF98
- 400 , #3DA778
- 500 , #008751
- 600 , #007345
- 700 , #005C37
- 800 , #00452A
- 900 , #002F1B
- 950 , #001C10
Accessibility
Colour helps people, but it must never be the only way something is shown. These checks apply to every page and component.
- Body text uses text/primary or text/secondary. Both pass 4.5:1 on every surface.
- Status colours always come with an icon and words, so they work without colour and in forced-colours mode.
- Control outlines reach 3:1. Use border/strong (4.2:1) or border/dark, never border/default or border/subtle.
- Focus rings reach 3:1. border/focus is 4.5:1 in the Light theme and 6.0:1 in Dark.
- Everything is checked in both Light and Dark themes, and in each brand mode.
Using the tokens
The same names work in Figma, code and WordPress.
- In Figma
Pick from the NDS Library Colors variables. Never type a hex value.
- In code
Use the CSS custom properties, which follow the token names, for example
var(--nds-color-action-primary-default).- In WordPress
Choose the brand in the theme settings. The colour roles update on their own.
- New colours
Don’t add colours in a project. Ask the NDS team, so the new colour is checked for contrast in every theme.
References
- WCAG 2.2: Contrast (minimum), 1.4.3 w3.org
- WCAG 2.2: Non-text contrast, 1.4.11 w3.org
- WCAG 2.2: Use of colour, 1.4.1 w3.org
- GOV.UK Design System: Colour design-system.service.gov.uk
Feedback
Is this page useful?