Only for shadcn/ui

Only is a shadcn/ui theme built around a near-black primary color (#181a1b) with muted light teal accents (#e8eded). The light mode uses a neutral background (#ffffff). Dark mode keeps the near-black primary (#181a1b) on a neutral background (#020808).

Color palette

TokenLightDark
Background
#ffffffwhite
#020808black
Foreground
#041515black
#fcfdfdwhite
Card
#ffffffwhite
#020808black
Card foreground
#041515black
#fcfdfdwhite
Popover
#ffffffwhite
#020808black
Popover foreground
#041515black
#fcfdfdwhite
Primary
#181a1bblack
#181a1bblack
Primary foreground
#afb5b6darkgray
#afb5b6darkgray
Secondary
#e8ededlavender
#171717black
Secondary foreground
#495a5bdarkslategray
#afb1b1darkgray
Muted
#d4e2e3gainsboro
#1c2b2bdarkslategray
Muted foreground
#525757dimgray
#a8adaddarkgray
Accent
#e8ededlavender
#171717black
Accent foreground
#495a5bdarkslategray
#afb1b1darkgray
Destructive
#b82a0afirebrick
#e9350corangered
Destructive foreground
#ffffffwhite
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#181a1bblack
#181a1bblack

Contrast

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

Light mode
Text on background18.69:1AAA
Text on card18.69:1AAA
Primary button8.37:1AAA
Secondary button6.12:1AA
Muted text5.52:1AA
Accent6.12:1AA
Destructive6.22:1AA
Dark mode
Text on background19.81:1AAA
Text on card19.81:1AAA
Primary button8.37:1AAA
Secondary button8.31:1AAA
Muted text6.48:1AA
Accent8.31:1AAA
Destructive4.23:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(1 0 180);
  --foreground: oklch(0.18 0.024 198.103);
  --muted: oklch(0.903 0.016 199.376);
  --muted-foreground: oklch(0.451 0.006 199.419);
  --popover: oklch(1 0 180);
  --popover-foreground: oklch(0.18 0.024 198.103);
  --card: oklch(1 0 180);
  --card-foreground: oklch(0.18 0.024 198.103);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.218 0.003 199.419);
  --primary-foreground: oklch(0.77 0.007 199.488);
  --secondary: oklch(0.942 0.005 199.538);
  --secondary-foreground: oklch(0.453 0.021 199.011);
  --accent: oklch(0.942 0.005 199.538);
  --accent-foreground: oklch(0.453 0.021 199.011);
  --destructive: oklch(0.512 0.183 33.039);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.218 0.003 199.419);
  --chart-1: oklch(0.218 0.003 199.419);
  --chart-2: oklch(0.942 0.005 199.538);
  --chart-3: oklch(0.942 0.005 199.538);
  --chart-4: oklch(0.964 0.003 199.564);
  --chart-5: oklch(0.219 0.005 199.29);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.124 0.013 197.705);
  --foreground: oklch(0.993 0.001 199.588);
  --muted: oklch(0.275 0.02 198.759);
  --muted-foreground: oklch(0.744 0.006 199.504);
  --popover: oklch(0.124 0.013 197.705);
  --popover-foreground: oklch(0.993 0.001 199.588);
  --card: oklch(0.124 0.013 197.705);
  --card-foreground: oklch(0.993 0.001 199.588);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.218 0.003 199.419);
  --primary-foreground: oklch(0.77 0.007 199.488);
  --secondary: oklch(0.205 0.001 199.559);
  --secondary-foreground: oklch(0.758 0.002 199.574);
  --accent: oklch(0.205 0.001 199.559);
  --accent-foreground: oklch(0.758 0.002 199.574);
  --destructive: oklch(0.608 0.22 32.853);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.218 0.003 199.419);
  --chart-1: oklch(0.218 0.003 199.419);
  --chart-2: oklch(0.205 0.001 199.559);
  --chart-3: oklch(0.205 0.001 199.559);
  --chart-4: oklch(0.238 0.001 199.554);
  --chart-5: oklch(0.219 0.005 199.29);
}