Gruvbox Material Dark is a shadcn/ui theme built around a muted orange primary color (#a89985) with neutral gray accents (#504e4e). The light mode uses a neutral background (#292828). Dark mode keeps the muted orange primary (#a89985) on a neutral background (#292828).
| Token | Light | Dark |
|---|---|---|
| Background | #292828darkslategray | #292828darkslategray |
| Foreground | #d3bd97tan | #d3bd97tan |
| Card | #242323black | #242323black |
| Card foreground | #dbc8a9wheat | #dbc8a9wheat |
| Popover | #212121black | #212121black |
| Popover foreground | #e2d4bbwheat | #e2d4bbwheat |
| Primary | #a89985rosybrown | #a89985rosybrown |
| Primary foreground | #000000black | #000000black |
| Secondary | #44403bdarkslategray | #44403bdarkslategray |
| Secondary foreground | #dbd9d6gainsboro | #dbd9d6gainsboro |
| Muted | #392d2ddarkslategray | #392d2ddarkslategray |
| Muted foreground | #bca9a9darkgray | #bca9a9darkgray |
| Accent | #504e4edarkslategray | #504e4edarkslategray |
| Accent foreground | #e8e8e8lavender | #e8e8e8lavender |
| Destructive | #ed5e45tomato | #ed5e45tomato |
| Destructive foreground | #000000black | #000000black |
| Border | #363636darkslategray | #363636darkslategray |
| Input | #3d3d3ddarkslategray | #3d3d3ddarkslategray |
| Ring | #a89985rosybrown | #a89985rosybrown |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 8.01:1 | AAA |
| Text on card | 9.55:1 | AAA |
| Primary button | 7.59:1 | AAA |
| Secondary button | 7.25:1 | AAA |
| Muted text | 5.91:1 | AA |
| Accent | 6.72:1 | AA |
| Destructive | 6.29:1 | AA |
| Text on background | 8.01:1 | AAA |
| Text on card | 9.55:1 | AAA |
| Primary button | 7.59:1 | AAA |
| Secondary button | 7.25:1 | AAA |
| Muted text | 5.91:1 | AA |
| Accent | 6.72:1 | AA |
| Destructive | 6.29:1 | AA |
Paste this into your globals.css to use Gruvbox Material Dark in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.279 0.001 17.229);
--foreground: oklch(0.808 0.057 81.216);
--muted: oklch(0.31 0.018 18.169);
--muted-foreground: oklch(0.752 0.021 17.636);
--popover: oklch(0.248 0.001 17.225);
--popover-foreground: oklch(0.875 0.037 81.421);
--card: oklch(0.258 0.001 17.226);
--card-foreground: oklch(0.841 0.047 81.34);
--border: oklch(0.331 0 180);
--input: oklch(0.361 0 180);
--primary: oklch(0.691 0.034 76.314);
--primary-foreground: oklch(0 0 0);
--secondary: oklch(0.375 0.01 76.504);
--secondary-foreground: oklch(0.887 0.005 76.627);
--accent: oklch(0.426 0.002 17.239);
--accent-foreground: oklch(0.931 0 17.167);
--destructive: oklch(0.662 0.181 32.127);
--destructive-foreground: oklch(0 0 0);
--ring: oklch(0.691 0.034 76.314);
--chart-1: oklch(0.691 0.034 76.314);
--chart-2: oklch(0.375 0.01 76.504);
--chart-3: oklch(0.426 0.002 17.239);
--chart-4: oklch(0.405 0.011 76.5);
--chart-5: oklch(0.695 0.04 76.226);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.279 0.001 17.229);
--foreground: oklch(0.808 0.057 81.216);
--muted: oklch(0.31 0.018 18.169);
--muted-foreground: oklch(0.752 0.021 17.636);
--popover: oklch(0.248 0.001 17.225);
--popover-foreground: oklch(0.875 0.037 81.421);
--card: oklch(0.258 0.001 17.226);
--card-foreground: oklch(0.841 0.047 81.34);
--border: oklch(0.331 0 180);
--input: oklch(0.361 0 180);
--primary: oklch(0.691 0.034 76.314);
--primary-foreground: oklch(0 0 0);
--secondary: oklch(0.375 0.01 76.504);
--secondary-foreground: oklch(0.887 0.005 76.627);
--accent: oklch(0.426 0.002 17.239);
--accent-foreground: oklch(0.931 0 17.167);
--destructive: oklch(0.662 0.181 32.127);
--destructive-foreground: oklch(0 0 0);
--ring: oklch(0.691 0.034 76.314);
--chart-1: oklch(0.691 0.034 76.314);
--chart-2: oklch(0.375 0.01 76.504);
--chart-3: oklch(0.426 0.002 17.239);
--chart-4: oklch(0.405 0.011 76.5);
--chart-5: oklch(0.695 0.04 76.226);
}