Blue for shadcn/ui

Blue is a shadcn/ui theme built around a muted blue primary color (#8086a8) with muted yellow accents (#a8a280). The light mode uses a neutral background (#ffffff). Dark mode keeps the muted blue primary (#8086a8) on a blue-tinted background (#06070e).

Color palette

TokenLightDark
Background
#ffffffwhite
#06070eblack
Foreground
#020308black
#ffffffwhite
Card
#fcfcfcsnow
#080912black
Card foreground
#010204black
#ffffffwhite
Popover
#fcfcfcsnow
#080912black
Popover foreground
#010204black
#ffffffwhite
Primary
#8086a8lightslategray
#8086a8lightslategray
Primary foreground
#000000black
#000000black
Secondary
#a8a280rosybrown
#a8a280rosybrown
Secondary foreground
#000000black
#000000black
Muted
#f2f1eewhitesmoke
#11110dblack
Muted foreground
#6f6c5ddimgray
#a29f90darkgray
Accent
#a8a280rosybrown
#a8a280rosybrown
Accent foreground
#000000black
#000000black
Destructive
#8f3704saddlebrown
#f97f39coral
Destructive foreground
#ffffffwhite
#000000black
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#8086a8lightslategray
#8086a8lightslategray

Contrast

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

Light mode
Text on background20.60:1AAA
Text on card20.30:1AAA
Primary button5.86:1AA
Secondary button8.15:1AAA
Muted text4.67:1AA
Accent8.15:1AAA
Destructive7.68:1AAA
Dark mode
Text on background20.07:1AAA
Text on card19.84:1AAA
Primary button5.86:1AA
Secondary button8.15:1AAA
Muted text7.12:1AAA
Accent8.15:1AAA
Destructive8.14:1AAA

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(1 0 180);
  --foreground: oklch(0.101 0.016 272.304);
  --muted: oklch(0.958 0.005 98.385);
  --muted-foreground: oklch(0.531 0.024 98.9);
  --popover: oklch(0.992 0 161.565);
  --popover-foreground: oklch(0.08 0.013 272.304);
  --card: oklch(0.992 0 161.565);
  --card-foreground: oklch(0.08 0.013 272.304);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.626 0.053 276.955);
  --primary-foreground: oklch(0 0 0);
  --secondary: oklch(0.709 0.048 99.148);
  --secondary-foreground: oklch(0 0 0);
  --accent: oklch(0.709 0.048 99.148);
  --accent-foreground: oklch(0 0 0);
  --destructive: oklch(0.456 0.131 43.485);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.626 0.053 276.955);
  --chart-1: oklch(0.626 0.053 276.955);
  --chart-2: oklch(0.709 0.048 99.148);
  --chart-3: oklch(0.709 0.048 99.148);
  --chart-4: oklch(0.73 0.045 99.079);
  --chart-5: oklch(0.62 0.061 276.69);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.133 0.016 274.624);
  --foreground: oklch(1 0 180);
  --muted: oklch(0.176 0.007 98.829);
  --muted-foreground: oklch(0.702 0.022 98.744);
  --popover: oklch(0.144 0.019 275.24);
  --popover-foreground: oklch(1 0 180);
  --card: oklch(0.144 0.019 275.24);
  --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.626 0.053 276.955);
  --primary-foreground: oklch(0 0 0);
  --secondary: oklch(0.709 0.048 99.148);
  --secondary-foreground: oklch(0 0 0);
  --accent: oklch(0.709 0.048 99.148);
  --accent-foreground: oklch(0 0 0);
  --destructive: oklch(0.725 0.169 47.532);
  --destructive-foreground: oklch(0 0 0);
  --ring: oklch(0.626 0.053 276.955);
  --chart-1: oklch(0.626 0.053 276.955);
  --chart-2: oklch(0.709 0.048 99.148);
  --chart-3: oklch(0.709 0.048 99.148);
  --chart-4: oklch(0.73 0.045 99.079);
  --chart-5: oklch(0.62 0.061 276.69);
}