Scheme for shadcn/ui

Scheme is a shadcn/ui theme built around an indigo primary color (#3d38dc) with yellow accents (#d6dc38). The light mode uses a neutral background (#f8f8fc). Dark mode keeps the indigo primary (#3d38dc) on a neutral background (#000000).

Color palette

TokenLightDark
Background
#f8f8fcghostwhite
#000000black
Foreground
#030208black
#f6f6f8whitesmoke
Card
#f5f5fawhitesmoke
#030303black
Card foreground
#010104black
#f9f9fbghostwhite
Popover
#f5f5fawhitesmoke
#030303black
Popover foreground
#010104black
#f9f9fbghostwhite
Primary
#3d38dcroyalblue
#3d38dcroyalblue
Primary foreground
#e6e5falavender
#e6e5falavender
Secondary
#d6dc38greenyellow
#d6dc38greenyellow
Secondary foreground
#3b3d0bdarkolivegreen
#3b3d0bdarkolivegreen
Muted
#f5f5ealinen
#14150ablack
Muted foreground
#6f6f58dimgray
#a7a790darkgray
Accent
#d6dc38greenyellow
#d6dc38greenyellow
Accent foreground
#3b3d0bdarkolivegreen
#3b3d0bdarkolivegreen
Destructive
#8d1d07darkred
#ea300borangered
Destructive foreground
#fcd2c9peachpuff
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#3d38dcroyalblue
#3d38dcroyalblue

Contrast

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

Light mode
Text on background19.52:1AAA
Text on card19.13:1AAA
Primary button6.08:1AA
Secondary button7.61:1AAA
Muted text4.67:1AA
Accent7.61:1AAA
Destructive6.56:1AA
Dark mode
Text on background19.45:1AAA
Text on card19.66:1AAA
Primary button6.08:1AA
Secondary button7.61:1AAA
Muted text7.53:1AAA
Accent7.61:1AAA
Destructive4.26:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.981 0.005 287.85);
  --foreground: oklch(0.096 0.02 284.2);
  --muted: oklch(0.967 0.014 108.199);
  --muted-foreground: oklch(0.536 0.036 109.124);
  --popover: oklch(0.971 0.007 287.804);
  --popover-foreground: oklch(0.076 0.016 284.2);
  --card: oklch(0.971 0.007 287.804);
  --card-foreground: oklch(0.076 0.016 284.2);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.47 0.237 273.79);
  --primary-foreground: oklch(0.929 0.029 287.355);
  --secondary: oklch(0.862 0.175 111.51);
  --secondary-foreground: oklch(0.346 0.068 111.395);
  --accent: oklch(0.862 0.175 111.51);
  --accent-foreground: oklch(0.346 0.068 111.395);
  --destructive: oklch(0.421 0.151 32.641);
  --destructive-foreground: oklch(0.898 0.05 31.253);
  --ring: oklch(0.47 0.237 273.79);
  --chart-1: oklch(0.47 0.237 273.79);
  --chart-2: oklch(0.862 0.175 111.51);
  --chart-3: oklch(0.862 0.175 111.51);
  --chart-4: oklch(0.87 0.169 111.328);
  --chart-5: oklch(0.467 0.245 272.937);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0 0 0);
  --foreground: oklch(0.975 0.003 287.886);
  --muted: oklch(0.19 0.02 109.752);
  --muted-foreground: oklch(0.723 0.033 108.771);
  --popover: oklch(0.092 0 180);
  --popover-foreground: oklch(0.983 0.002 287.904);
  --card: oklch(0.092 0 180);
  --card-foreground: oklch(0.983 0.002 287.904);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.47 0.237 273.79);
  --primary-foreground: oklch(0.929 0.029 287.355);
  --secondary: oklch(0.862 0.175 111.51);
  --secondary-foreground: oklch(0.346 0.068 111.395);
  --accent: oklch(0.862 0.175 111.51);
  --accent-foreground: oklch(0.346 0.068 111.395);
  --destructive: oklch(0.607 0.224 32.205);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.47 0.237 273.79);
  --chart-1: oklch(0.47 0.237 273.79);
  --chart-2: oklch(0.862 0.175 111.51);
  --chart-3: oklch(0.862 0.175 111.51);
  --chart-4: oklch(0.87 0.169 111.328);
  --chart-5: oklch(0.467 0.245 272.937);
}