Generate feedback colors (success, warning, error, and info) for shadcn/ui

Go to generator

10000+Themes for shadcn/ui

green for shadcn/ui

green is a shadcn/ui theme built around a muted green primary color (#55784a) with muted light green accents (#c4cdc1). The light mode uses a neutral background (#f9fcf7). Dark mode keeps the muted green primary (#55784a) on a neutral background (#040802).

Color palette

TokenLightDark
Background
#f9fcf7mintcream
#040802black
Foreground
#071005black
#f9fcf8mintcream
Card
#f9fcf7mintcream
#040802black
Card foreground
#071005black
#f9fcf8mintcream
Popover
#f9fcf7mintcream
#040802black
Popover foreground
#071005black
#f9fcf8mintcream
Primary
#55784adarkolivegreen
#55784adarkolivegreen
Primary foreground
#ffffffwhite
#ffffffwhite
Secondary
#d5d9d4lightgrey
#191a19black
Secondary foreground
#3b413adarkslategray
#b2b3b2darkgray
Muted
#e3eae1gainsboro
#171e15black
Muted foreground
#4b5e45darkolivegreen
#a7baa1darkgray
Accent
#c4cdc1silver
#313630darkslategray
Accent foreground
#2b3329darkslategray
#cacfc9lightgrey
Destructive
#b42808firebrick
#f4421aorangered
Destructive foreground
#ffffffwhite
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#55784adarkolivegreen
#55784adarkolivegreen

Contrast

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

Light mode
Text on background18.73:1AAA
Text on card18.73:1AAA
Primary button5.02:1AA
Secondary button7.32:1AAA
Muted text5.73:1AA
Accent7.98:1AAA
Destructive6.45:1AA
Dark mode
Text on background19.52:1AAA
Text on card19.52:1AAA
Primary button5.02:1AA
Secondary button8.30:1AAA
Muted text8.24:1AAA
Accent7.79:1AAA
Destructive3.71:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.988 0.008 137.776);
  --foreground: oklch(0.159 0.028 136.72);
  --muted: oklch(0.93 0.014 137.789);
  --muted-foreground: oklch(0.459 0.045 137.957);
  --popover: oklch(0.988 0.008 137.776);
  --popover-foreground: oklch(0.159 0.028 136.72);
  --card: oklch(0.988 0.008 137.776);
  --card-foreground: oklch(0.159 0.028 136.72);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.534 0.081 138.122);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.88 0.008 137.778);
  --secondary-foreground: oklch(0.367 0.014 137.831);
  --accent: oklch(0.838 0.02 137.803);
  --accent-foreground: oklch(0.31 0.021 137.884);
  --destructive: oklch(0.504 0.18 32.995);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.534 0.081 138.122);
  --chart-1: oklch(0.534 0.081 138.122);
  --chart-2: oklch(0.88 0.008 137.778);
  --chart-3: oklch(0.838 0.02 137.803);
  --chart-4: oklch(0.903 0.006 137.775);
  --chart-5: oklch(0.54 0.09 138.184);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.124 0.021 136.13);
  --foreground: oklch(0.987 0.006 137.774);
  --muted: oklch(0.225 0.02 137.936);
  --muted-foreground: oklch(0.767 0.04 137.856);
  --popover: oklch(0.124 0.021 136.13);
  --popover-foreground: oklch(0.987 0.006 137.774);
  --card: oklch(0.124 0.021 136.13);
  --card-foreground: oklch(0.987 0.006 137.774);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.534 0.081 138.122);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.216 0.001 137.772);
  --secondary-foreground: oklch(0.766 0.002 137.769);
  --accent: oklch(0.327 0.012 137.829);
  --accent-foreground: oklch(0.849 0.01 137.782);
  --destructive: oklch(0.64 0.22 33.464);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.534 0.081 138.122);
  --chart-1: oklch(0.534 0.081 138.122);
  --chart-2: oklch(0.216 0.001 137.772);
  --chart-3: oklch(0.327 0.012 137.829);
  --chart-4: oklch(0.249 0.001 137.773);
  --chart-5: oklch(0.54 0.09 138.184);
}