Frugal for shadcn/ui

Frugal is a shadcn/ui theme built around a vivid purple primary color (#c207df) with neutral gray accents (#d9d8d9). The light mode uses a neutral background (#ffffff). Dark mode keeps the vivid purple primary (#c207df) on a purple-tinted background (#0a050a).

Color palette

TokenLightDark
Background
#ffffffwhite
#0a050ablack
Foreground
#040104black
#ffffffwhite
Card
#ffffffwhite
#0a050ablack
Card foreground
#040104black
#ffffffwhite
Popover
#ffffffwhite
#0a050ablack
Popover foreground
#040104black
#ffffffwhite
Primary
#c207dfdarkviolet
#c207dfdarkviolet
Primary foreground
#ffffffwhite
#ffffffwhite
Secondary
#d9d8d9gainsboro
#352537darkslategray
Secondary foreground
#403f40darkslategray
#cfbcd2thistle
Muted
#e2d9e3gainsboro
#251c26black
Muted foreground
#564c57dimgray
#b2a8b3darkgray
Accent
#d9d8d9gainsboro
#352537darkslategray
Accent foreground
#403f40darkslategray
#cfbcd2thistle
Destructive
#650b01maroon
#fe1b01red
Destructive foreground
#fea49alightsalmon
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#c207dfdarkviolet
#c207dfdarkviolet

Contrast

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

Light mode
Text on background20.76:1AAA
Text on card20.76:1AAA
Primary button4.79:1AA
Secondary button7.39:1AAA
Muted text5.92:1AA
Accent7.39:1AAA
Destructive6.84:1AA
Dark mode
Text on background20.21:1AAA
Text on card20.21:1AAA
Primary button4.79:1AA
Secondary button8.03:1AAA
Muted text7.18:1AAA
Accent8.03:1AAA
Destructive3.92:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(1 0 180);
  --foreground: oklch(0.085 0.018 323.294);
  --muted: oklch(0.894 0.017 321.646);
  --muted-foreground: oklch(0.43 0.022 321.735);
  --popover: oklch(1 0 180);
  --popover-foreground: oklch(0.085 0.018 323.294);
  --card: oklch(1 0 180);
  --card-foreground: oklch(0.085 0.018 323.294);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.591 0.28 320.896);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.884 0.001 321.596);
  --secondary-foreground: oklch(0.37 0.003 321.612);
  --accent: oklch(0.884 0.001 321.596);
  --accent-foreground: oklch(0.37 0.003 321.612);
  --destructive: oklch(0.326 0.124 31.511);
  --destructive-foreground: oklch(0.805 0.11 26.655);
  --ring: oklch(0.591 0.28 320.896);
  --chart-1: oklch(0.591 0.28 320.896);
  --chart-2: oklch(0.884 0.001 321.596);
  --chart-3: oklch(0.884 0.001 321.596);
  --chart-4: oklch(0.908 0.001 321.595);
  --chart-5: oklch(0.596 0.284 320.787);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.127 0.017 322.67);
  --foreground: oklch(1 0 180);
  --muted: oklch(0.241 0.024 321.855);
  --muted-foreground: oklch(0.742 0.02 321.666);
  --popover: oklch(0.127 0.017 322.67);
  --popover-foreground: oklch(1 0 180);
  --card: oklch(0.127 0.017 322.67);
  --card-foreground: oklch(1 0 180);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.591 0.28 320.896);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.29 0.039 321.939);
  --secondary-foreground: oklch(0.817 0.038 321.719);
  --accent: oklch(0.29 0.039 321.939);
  --accent-foreground: oklch(0.817 0.038 321.719);
  --destructive: oklch(0.632 0.251 30.249);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.591 0.28 320.896);
  --chart-1: oklch(0.591 0.28 320.896);
  --chart-2: oklch(0.29 0.039 321.939);
  --chart-3: oklch(0.29 0.039 321.939);
  --chart-4: oklch(0.319 0.045 321.949);
  --chart-5: oklch(0.596 0.284 320.787);
}