Buttery for shadcn/ui

Buttery is a shadcn/ui theme built around a muted green primary color (#a1ab9b) with muted violet accents (#a69bab). The light mode uses a neutral background (#fcfdfc). Dark mode keeps the muted green primary (#a1ab9b) on a green-tinted background (#060c03).

Color palette

TokenLightDark
Background
#fcfdfcwhite
#060c03black
Foreground
#020401black
#fcfdfcwhite
Card
#fcfdfcwhite
#060c03black
Card foreground
#020401black
#fcfdfcwhite
Popover
#fcfdfcwhite
#060c03black
Popover foreground
#020401black
#fcfdfcwhite
Primary
#a1ab9bdarkgray
#a1ab9bdarkgray
Primary foreground
#0a0b09black
#0a0b09black
Secondary
#a69babdarkgray
#a69babdarkgray
Secondary foreground
#0a090bblack
#0a090bblack
Muted
#d9d7dbgainsboro
#272428darkslategray
Muted foreground
#413c44darkslategray
#c0bbc3silver
Accent
#a69babdarkgray
#a69babdarkgray
Accent foreground
#0a090bblack
#0a090bblack
Destructive
#8d2407saddlebrown
#f34a1borangered
Destructive foreground
#fcd5cabisque
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#a1ab9bdarkgray
#a1ab9bdarkgray

Contrast

WCAG 2 contrast ratios between each background and its foreground color.

Light mode
Text on background20.21:1AAA
Text on card20.21:1AAA
Primary button8.30:1AAA
Secondary button7.46:1AAA
Muted text7.51:1AAA
Accent7.46:1AAA
Destructive6.51:1AA
Dark mode
Text on background19.39:1AAA
Text on card19.39:1AAA
Primary button8.30:1AAA
Secondary button7.46:1AAA
Muted text8.11:1AAA
Accent7.46:1AAA
Destructive3.61:1AA Large

CSS variables

Paste this into your globals.css to use Buttery in your shadcn/ui project.

:root {
  --radius: 0.5rem;
  --background: oklch(0.994 0.002 134.233);
  --foreground: oklch(0.101 0.021 132.285);
  --muted: oklch(0.882 0.006 314.183);
  --muted-foreground: oklch(0.364 0.015 314);
  --popover: oklch(0.994 0.002 134.233);
  --popover-foreground: oklch(0.101 0.021 132.285);
  --card: oklch(0.994 0.002 134.233);
  --card-foreground: oklch(0.101 0.021 132.285);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.729 0.026 134.426);
  --primary-foreground: oklch(0.148 0.004 134.17);
  --secondary: oklch(0.704 0.027 314.012);
  --secondary-foreground: oklch(0.144 0.004 314.15);
  --accent: oklch(0.704 0.027 314.012);
  --accent-foreground: oklch(0.144 0.004 314.15);
  --destructive: oklch(0.427 0.144 34.762);
  --destructive-foreground: oklch(0.903 0.047 35.949);
  --ring: oklch(0.729 0.026 134.426);
  --chart-1: oklch(0.729 0.026 134.426);
  --chart-2: oklch(0.704 0.027 314.012);
  --chart-3: oklch(0.704 0.027 314.012);
  --chart-4: oklch(0.729 0.024 314.037);
  --chart-5: oklch(0.734 0.035 134.494);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.144 0.023 132.823);
  --foreground: oklch(0.993 0.002 134.231);
  --muted: oklch(0.266 0.008 314.057);
  --muted-foreground: oklch(0.8 0.012 314.137);
  --popover: oklch(0.144 0.023 132.823);
  --popover-foreground: oklch(0.993 0.002 134.231);
  --card: oklch(0.144 0.023 132.823);
  --card-foreground: oklch(0.993 0.002 134.231);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.729 0.026 134.426);
  --primary-foreground: oklch(0.148 0.004 134.17);
  --secondary: oklch(0.704 0.027 314.012);
  --secondary-foreground: oklch(0.144 0.004 314.15);
  --accent: oklch(0.704 0.027 314.012);
  --accent-foreground: oklch(0.144 0.004 314.15);
  --destructive: oklch(0.646 0.213 35.055);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.729 0.026 134.426);
  --chart-1: oklch(0.729 0.026 134.426);
  --chart-2: oklch(0.704 0.027 314.012);
  --chart-3: oklch(0.704 0.027 314.012);
  --chart-4: oklch(0.729 0.024 314.037);
  --chart-5: oklch(0.734 0.035 134.494);
}