Skip to content

Tailwind CSS v4 default palette

Tailwind green-500: #00C950

In Tailwind CSS v4, green-500 is defined as --color-green-500: oklch(72.3% 0.219 149.579), which is #00C950 in hex and rgb(0, 201, 80): a light, vivid green. In Tailwind v3, green-500 was #22C55E.

green-500#00C950

In OKLCH, green-500 has a lightness of 72.3%, chroma 0.219 and hue 149.6°. It is the most saturated shade of the green scale.

This OKLCH value lies outside sRGB. The hex #00C950 is the sRGB fallback from the CSS Color 4 gamut mapping algorithm; on Display P3 screens browsers show a more saturated color, close to color(display-p3 0.3087 0.7748 0.3743).

In v3, green-500 was #22C55E. The v4 value is ΔE OK 2.7 away; v4 is more saturated.

Tailwind green is the standard success color; in v4 its mid shades moved to a more saturated OKLCH green than the v3 hex values.

Color codes for green-500

Color codes for green-500
Tailwind v4 token--color-green-500
OKLCH (source value)oklch(72.3% 0.219 149.579)
HEX#00C950
RGBrgb(0, 201, 80)
HSLhsl(144, 100%, 39%)
HWBhwb(144 0% 21%)
CMYK (naive, no ICC profile)cmyk(100%, 0%, 60%, 21%)
Decimal51,536
Display P3color(display-p3 0.3087 0.7748 0.3743)
Tailwind v3 hex#22C55E
Utility classesbg-green-500, text-green-500, border-green-500

Tailwind green scale

Contrast and accessibility

On green-500, black text has a contrast ratio of 9.47:1 and passes AAA at any text size; white text reaches 2.21:1.

WCAG 2.2 contrast ratios (success criteria 1.4.3 and 1.4.6: AA needs 4.5:1 for normal text and 3:1 for large text, AAA needs 7:1 and 4.5:1). APCA Lc is the lightness contrast from the APCA-W3 0.0.98G model proposed for WCAG 3; a higher absolute value is more readable, and Lc 75 is its suggested minimum for body text.

Contrast and accessibility
PairRatioAAAA largeAAAAAA largeAPCA Lc
Black text on green-5009.47:1PassPassPassPass61.1
White text on green-5002.21:1FailFailFailFail−47.6
Green-500 text on white2.21:1FailFailFailFail42.9
Green-500 text on black9.47:1PassPassPassPass−59.3

Tints and shades

Each step mixes var(--color-green-500) with white (tints) or black (shades) in gamma-encoded sRGB, the same result as color-mix(in srgb, var(--color-green-500), white 25%) in CSS.

Tints (mixed with white)

  1. 5%
    #0dcc59
  2. 15%
    #26d16a
  3. 25%
    #40d77c
  4. 35%
    #59dc8d
  5. 45%
    #73e19f
  6. 55%
    #8ce7b0
  7. 65%
    #a6ecc2
  8. 75%
    #bff2d3
  9. 85%
    #d9f7e5
  10. 95%
    #f2fcf6

Shades (mixed with black)

  1. 5%
    #00bf4c
  2. 15%
    #00ab44
  3. 25%
    #00973c
  4. 35%
    #008334
  5. 45%
    #006f2c
  6. 55%
    #005a24
  7. 65%
    #00461c
  8. 75%
    #003214
  9. 85%
    #001e0c
  10. 95%
    #000a04

Color harmonies

Rotating the hue in OKLCH while keeping lightness and chroma, green-500's complementary color is #ED68E6 (close to orchid), its analogous colors are #98B500 and #00C3A8, and its triadic partners are #7D9DFF and #FF6A57. For text on top, black gives the higher contrast.

Color harmonies
HarmonyRotationColor
Complementary+180°#ed68e6
Analogous−30°, +30°#98b500#00c3a8
Triadic+120°, +240°#7d9dff#ff6a57
Split-complementary+150°, +210°#b983ff#ff5ca1

Computed in OKLCH: the hue is rotated by 180° (complementary), ±30° (analogous), ±120° (triadic) and 180° ±30° (split-complementary) while lightness and chroma stay fixed. Results that fall outside sRGB are brought back with the CSS Color 4 gamut mapping algorithm. Because this uses OKLCH, the values differ from tools that rotate hue in HSL, but every color keeps the same perceived lightness.

Warm or cool?

Tailwind green-500 is a cool color: its hue is 144° on the HSL wheel, in the green, blue and violet range that is conventionally called cool.

Nearest named and Tailwind colors

Distance is ΔE OK, the Euclidean distance in OKLab multiplied by 100. Values under about 2 are hard to tell apart side by side.

Nearest CSS named colors

Nearest CSS named colors
ColorHEXΔE OK
limegreen#32cd323.4
mediumseagreen#3cb3718.6
yellowgreen#9acd3210.7

Nearest Tailwind v4 colors

Nearest Tailwind v4 colors
ColorHEXΔE OK
green-400#05df727.0
emerald-500#00bc7d7.1
emerald-400#00d4927.6

Code snippets

Tailwind CSS
<div class="bg-green-500 text-black">...</div>
<p class="text-green-500 border-green-500">...</p>
CSS
.element {
  color: var(--color-green-500);
  background-color: oklch(72.3% 0.219 149.579);
  border-color: #00c950;
  outline-color: rgb(0 201 80);
}
SwiftUI
import SwiftUI

extension Color {
  static let green500 = Color(red: 0.000, green: 0.788, blue: 0.314)
}
Jetpack Compose
import androidx.compose.ui.graphics.Color

val Green500 = Color(0xFF00C950)
Flutter
import 'package:flutter/material.dart';

const green500 = Color(0xFF00C950);
Android XML
<!-- res/values/colors.xml -->
<color name="green_500">#00C950</color>

Frequently asked questions

What is the hex code for Tailwind green-500?
In Tailwind CSS v4, green-500 is oklch(72.3% 0.219 149.579), which converts to #00C950 (rgb(0, 201, 80)) in sRGB after gamut mapping, because the OKLCH value is outside sRGB. In Tailwind v3 the same name was #22C55E.
What is the difference between green-500 in Tailwind v3 and v4?
v3 used the hex #22C55E; v4 redefined the palette in OKLCH as oklch(72.3% 0.219 149.579). In v3, green-500 was #22C55E. The v4 value is ΔE OK 2.7 away; v4 is more saturated.
How do I use green-500 in plain CSS?
Tailwind v4 defines every palette color as a theme variable, so in CSS you write var(--color-green-500). By default Tailwind only emits the variables your project uses; @theme static emits all of them.
Can you use white text on green-500?
White text on green-500 has a contrast ratio of 2.21:1, which fails AA even for large text under WCAG 2.2. Black text reaches 9.47:1 and passes both AA and AAA. In APCA terms that is Lc −47.6 for white and Lc 61.1 for black.
Which CSS named color is closest to green-500?
The closest is limegreen (#32CD32) at ΔE OK 3.4, followed by mediumseagreen and yellowgreen.

Last reviewed by Arielton Oberek.