shadcn token

shadcn Green in OKLCH

Quick answer: shadcn Green is #22C55E, which converts to oklch(0.723 0.192 149.60). On white, it has a WCAG contrast ratio of 2.27:1 and an APCA score of Lc +44.33.

This falls below the WCAG 2.2 AA Large text threshold (3:1) on white; pair with a darker foreground. The OKLCH base colors used here are available in shadcn/ui since the Tailwind v4 update (February 2025), with 92% global browser support for OKLCH notation (caniuse, April 2026).

oklch(0.723 0.192 149.60)

shadcn Green is a shadcn theme token. This page frames #22C55E as a theme token: paste the :root and .dark blocks below to theme every component at once.

  • Specs

    oklch(0.723 0.192 149.60)
    #22C55E

    Highest contrast: black

    9.21:1
    Normal AAmeets WCAG 2.2
    Normal AAAmeets WCAG 2.2
    Large AAmeets WCAG 2.2
    Large AAAmeets WCAG 2.2
    Lc -57.80
  • Accessibility lens

    • Base#22C55E
    • 300#7BDF91
    • 500#22C55E
    • 700#007623

    Toggle a lens to preview this color under color vision differences.

How does shadcn Green go from primitive to component?

  1. Primitive
  2. Semantic
  3. Component

Primitive

The raw value, before it means anything.

hex
#22C55E
oklch
oklch(0.723 0.192 149.60)

Semantic

Bound to a role token that UI reads by name.

--primary: #22C55E

One primitive feeds the role. --primary then drives --ring and the hover and active states below, so a single value stays in sync everywhere.

Component

Applied to real UI across states.

AAA9.21:1
DefaultSave paletteNew
HoverSave paletteNew
ActiveSave paletteNew
DisabledSave paletteNew

On-color text: black (9.21:1 on #22C55E).

How does shadcn Green scale from 50 to 950?

shadcn Green
50 to 950
#E4FDE8
#C6F2CD
#A2E9AF
#7BDF91
#53D376
#22C55E
#009D3E
#007623
#00510E
#002D00
#000E00
  • 50oklch(0.970 0.038 150.05)
  • 100oklch(0.920 0.067 149.53)
  • 200oklch(0.872 0.107 149.46)
  • 300oklch(0.823 0.145 149.44)
  • 400oklch(0.773 0.173 149.50)
  • 500oklch(0.723 0.192 149.58)
  • 600oklch(0.607 0.175 148.05)
  • 700oklch(0.492 0.150 146.02)
  • 800oklch(0.378 0.121 144.49)
  • 900oklch(0.257 0.088 142.50)
  • 950oklch(0.142 0.048 142.50)

How does shadcn Green score on WCAG 2.2 contrast?

Every fg × bg combination, with WCAG 2.2 verdicts.

AAA (7:1+)
AA (4.5:1+)
Below AA (under 4.5:1)
Select a pair for ratio and APCA Lc

Does shadcn Green pass WCAG 2.2 on common neutral backgrounds?

  • Aa2.27Below AA

    White #FFFFFF

  • Aa2.09Below AA

    Neutral 100 #F5F5F5

  • Aa1.80Below AA

    Neutral 200 #E5E5E5

  • Aa1.10Below AA

    Neutral 400 #A3A3A3

  • Aa3.42Below AA

    Neutral 600 #525252

  • Aa7.86AAA

    Neutral 900 #171717

  • Aa9.21AAA

    Black #000000

What palettes pair with shadcn Green?

  • Analogous

    • #6EC522
    • #2AC522
    • #22C55E
    • #22C5A2
    • #22A4C5
  • Complementary

    • #52E187
    • #22C55E
  • Triadic

    • #22C55E
    • #147739
    • #5E22C5

Where should you use shadcn Green in production UI?

bars: primary-600 vs secondary-600
Monthly revenue
$48,219
text: neutral-900
+12.4%accent-50 / accent-700
This period Last period
JanFebMarAprMayJun
bg: primary-500 · fg: black
Step 2 of 3
Export your first design system this week.
Continue black / primary-500Skip for now
bg: accent-50 · fg: accent-700
3 tokens changed
Review them before your next export.
Review changes
avatars: solid fills · tags: tints
Team
MOprimary-500 / blackJLsecondary-500 / blackARaccent-500 / black+3neutral-700 / white
Newprimary-500 / blackLiveaccent-50 / accent-700In reviewsecondary-50 / secondary-700Draftneutral-50 / neutral-700
focus: primary-600 · border: neutral-500
Project name
Paletta web
border: primary-600 · ring: primary-100
Used in exported token names.
primary-600 / blackInclude dark mode
Add high contrast theme
Create projectprimary-500 / blackCancel
active tab: primary-700 · rules: neutral-100
All projectsSharedArchived
ProjectStatus
Marketing site
Updated 2h ago
Liveaccent-50 / accent-700
Mobile app
Updated yesterday
In reviewsecondary-50 / secondary-700
Docs
Updated 3d ago
Draftneutral-50 / neutral-700
toggle: primary-600 · progress: secondary-600
Notifications
Weekly digestprimary-600 / card
Product updatesneutral-500
Token quota640 of 1,000
secondary-600 on neutral-50
bg: neutral-900
--primary#22C55E
--secondary#3AAD9D
--accent#4AAD3A
--neutral#78877D
line: accent-600
Active users
12,480
+8.1% this weektext: accent-700
icon: secondary-500 · action: primary-700secondary-500 / black
Palette exported
tokens.css is ready to use.
Undo

Notes on shadcn Green

The shadcn green preset is a fresh, slightly cool green, oklch(0.723 0.192 149.6), aimed at success themes and positive accents. It is bright, so the usual rule holds: on white it is Below AA (2.27:1, APCA Lc +44.33), unfit for small text on a light page, while on a near-black surface it reaches WCAG 2.2 AAA (9.21:1, APCA Lc -57.8). The complementary #52E187 keeps a tonal mint, while the triad reaches a deep #147739 and a purple #5E22C5. What sets this green apart is how hard it falls under the accessibility lens: protanopia and deuteranopia desaturate it almost to gray (#696A77 and #5F537D), so for many red-green viewers it barely reads as a color, let alone as green. If this green marks success, it must be joined by an icon or label, and it should never be the only thing separating it from a red destructive state.

shadcn :root block

:root {
  --background: 120 7% 97%;
  --foreground: 140 6% 10%;
  --card: 120 7% 97%;
  --card-foreground: 140 6% 10%;
  --popover: 120 7% 97%;
  --popover-foreground: 140 6% 10%;
  --primary: 142 71% 45%;
  --primary-foreground: 0 0% 0%;
  --secondary: 169 44% 85%;
  --secondary-foreground: 170 100% 8%;
  --muted: 120 7% 94%;
  --muted-foreground: 140 6% 50%;
  --accent: 111 51% 85%;
  --accent-foreground: 120 100% 8%;
  --destructive: 0 72% 51%;
  --destructive-foreground: 0 0% 100%;
  --border: 140 5% 88%;
  --input: 140 5% 88%;
  --ring: 142 71% 45%;
  --radius: 0.5rem;
}

.dark {
  --background: 150 7% 6%;
  --foreground: 120 7% 97%;
  --card: 140 6% 10%;
  --card-foreground: 120 7% 97%;
  --popover: 140 6% 10%;
  --popover-foreground: 120 7% 97%;
  --primary: 136 59% 58%;
  --primary-foreground: 0 0% 0%;
  --secondary: 172 100% 14%;
  --secondary-foreground: 169 44% 85%;
  --muted: 140 7% 18%;
  --muted-foreground: 142 6% 64%;
  --accent: 120 100% 14%;
  --accent-foreground: 111 51% 85%;
  --destructive: 0 72% 51%;
  --destructive-foreground: 0 0% 100%;
  --border: 140 7% 18%;
  --input: 140 7% 18%;
  --ring: 136 59% 58%;
  --radius: 0.5rem;
}

How do you export shadcn Green as design tokens?

Export a W3C DTCG token document for the shadcn Green 50 to 950 scale, ready for Style Dictionary or any DTCG aware pipeline.

FAQ

Frequently asked questions

shadcn Green (#22C55E) is oklch(0.723 0.192 149.6) in the OKLCH color space.

shadcn Green passes WCAG 2.2 AA on black for normal text. Contrast ratios: 2.27:1 on white, 9.21:1 on black.

On white, shadcn Green has an APCA Lc of 44.3. On black, Lc is -57.8. APCA is a perceptual contrast model, not a WCAG compliance standard.

Paste the snippet above into your globals.css (with :root and .dark blocks).

Under deuteranopia (most common, around 5 percent of men), shadcn Green simulates to #5f537d. Under protanopia it shifts to #696a77. Under tritanopia it appears as #2a8b8f. Always pair color with shape, label, or icon for accessibility.

Ready to build your color system?

Free forever, no credit card, Pro when you need more.

Built by a product designer who ships to code.