Fifth is a shadcn/ui theme built around a neutral gray primary color (#646b73) with neutral gray accents (#736b64). The light mode uses a neutral background (#fbfcfe). Dark mode keeps the neutral gray primary (#646b73) on a neutral background (#010304).
| Token | Light | Dark |
|---|---|---|
| Background | #fbfcfewhite | #010304black |
| Foreground | #020508black | #fcfcfdwhite |
| Card | #fbfcfewhite | #010304black |
| Card foreground | #020508black | #fcfcfdwhite |
| Popover | #fbfcfewhite | #010304black |
| Popover foreground | #020508black | #fcfcfdwhite |
| Primary | #646b73dimgray | #646b73dimgray |
| Primary foreground | #ffffffwhite | #ffffffwhite |
| Secondary | #736b64dimgray | #736b64dimgray |
| Secondary foreground | #ffffffwhite | #ffffffwhite |
| Muted | #ebe8e6linen | #191714black |
| Muted foreground | #5b5752dimgray | #ada8a4darkgray |
| Accent | #736b64dimgray | #736b64dimgray |
| Accent foreground | #ffffffwhite | #ffffffwhite |
| Destructive | #881b02darkred | #fb4218orangered |
| Destructive foreground | #fec9bepink | #ffffffwhite |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #646b73dimgray | #646b73dimgray |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 19.95:1 | AAA |
| Text on card | 19.95:1 | AAA |
| Primary button | 5.39:1 | AA |
| Secondary button | 5.23:1 | AA |
| Muted text | 5.87:1 | AA |
| Accent | 5.23:1 | AA |
| Destructive | 6.52:1 | AA |
| Text on background | 20.19:1 | AAA |
| Text on card | 20.19:1 | AAA |
| Primary button | 5.39:1 | AA |
| Secondary button | 5.23:1 | AA |
| Muted text | 7.58:1 | AAA |
| Accent | 5.23:1 | AA |
| Destructive | 3.55:1 | AA Large |
Paste this into your globals.css to use Fifth in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.992 0.002 247.847);
--foreground: oklch(0.112 0.011 240.466);
--muted: oklch(0.932 0.004 67.77);
--muted-foreground: oklch(0.458 0.009 67.602);
--popover: oklch(0.992 0.002 247.847);
--popover-foreground: oklch(0.112 0.011 240.466);
--card: oklch(0.992 0.002 247.847);
--card-foreground: oklch(0.112 0.011 240.466);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.524 0.015 248.114);
--primary-foreground: oklch(1 0 180);
--secondary: oklch(0.533 0.015 67.5);
--secondary-foreground: oklch(1 0 180);
--accent: oklch(0.533 0.015 67.5);
--accent-foreground: oklch(1 0 180);
--destructive: oklch(0.408 0.147 33.255);
--destructive-foreground: oklch(0.88 0.062 32.856);
--ring: oklch(0.524 0.015 248.114);
--chart-1: oklch(0.524 0.015 248.114);
--chart-2: oklch(0.533 0.015 67.5);
--chart-3: oklch(0.533 0.015 67.5);
--chart-4: oklch(0.559 0.016 67.497);
--chart-5: oklch(0.523 0.021 248.236);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.089 0.009 240.893);
--foreground: oklch(0.992 0.001 247.828);
--muted: oklch(0.206 0.006 67.464);
--muted-foreground: oklch(0.735 0.008 67.702);
--popover: oklch(0.089 0.009 240.893);
--popover-foreground: oklch(0.992 0.001 247.828);
--card: oklch(0.089 0.009 240.893);
--card-foreground: oklch(0.992 0.001 247.828);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.524 0.015 248.114);
--primary-foreground: oklch(1 0 180);
--secondary: oklch(0.533 0.015 67.5);
--secondary-foreground: oklch(1 0 180);
--accent: oklch(0.533 0.015 67.5);
--accent-foreground: oklch(1 0 180);
--destructive: oklch(0.652 0.227 33.328);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.524 0.015 248.114);
--chart-1: oklch(0.524 0.015 248.114);
--chart-2: oklch(0.533 0.015 67.5);
--chart-3: oklch(0.533 0.015 67.5);
--chart-4: oklch(0.559 0.016 67.497);
--chart-5: oklch(0.523 0.021 248.236);
}