Skip to content

Tailwind CSS v4 default palette

Tailwind purple-800: #6E11B0

In Tailwind CSS v4, purple-800 is defined as --color-purple-800: oklch(43.8% 0.218 303.724), which is #6E11B0 in hex and rgb(110, 17, 176): a dark, vivid violet. In Tailwind v3, purple-800 was #6B21A8.

purple-800#6E11B0

In OKLCH, purple-800 has a lightness of 43.8%, chroma 0.218 and hue 303.7°.

The value fits inside sRGB, so the hex #6E11B0 represents it without loss on any screen.

In v3, purple-800 was #6B21A8. The v4 value is ΔE OK 2.0 away, below the point where most people can tell them apart; v4 is more saturated.

Tailwind purple is a redder, more magenta-leaning violet than violet, with very high chroma in its mid shades.

Color codes for purple-800

Color codes for purple-800
Tailwind v4 token--color-purple-800
OKLCH (source value)oklch(43.8% 0.218 303.724)
HEX#6E11B0
RGBrgb(110, 17, 176)
HSLhsl(275, 82%, 38%)
HWBhwb(275 7% 31%)
CMYK (naive, no ICC profile)cmyk(37%, 90%, 0%, 31%)
Decimal7,213,488
Tailwind v3 hex#6B21A8
Utility classesbg-purple-800, text-purple-800, border-purple-800

Tailwind purple scale

Contrast and accessibility

On purple-800, white text has a contrast ratio of 8.86:1 and passes AAA at any text size; black text reaches 2.37: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 purple-8002.37:1FailFailFailFail15.4
White text on purple-8008.86:1PassPassPassPass−93.2
Purple-800 text on white8.86:1PassPassPassPass88.6
Purple-800 text on black2.37:1FailFailFailFail−13.6

Tints and shades

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

Tints (mixed with white)

  1. 5%
    #751db4
  2. 15%
    #8435bc
  3. 25%
    #924dc4
  4. 35%
    #a164cc
  5. 45%
    #af7cd4
  6. 55%
    #be94db
  7. 65%
    #ccace3
  8. 75%
    #dbc4eb
  9. 85%
    #e9dbf3
  10. 95%
    #f8f3fb

Shades (mixed with black)

  1. 5%
    #6910a7
  2. 15%
    #5e0e96
  3. 25%
    #530d84
  4. 35%
    #480b72
  5. 45%
    #3d0961
  6. 55%
    #31084f
  7. 65%
    #27063e
  8. 75%
    #1c042c
  9. 85%
    #11031a
  10. 95%
    #060109

Color harmonies

Rotating the hue in OKLCH while keeping lightness and chroma, purple-800's complementary color is #445C00 (close to darkgreen), its analogous colors are #3733C6 and #900082, and its triadic partners are #7E3F00 and #006358. For text on top, white gives the higher contrast.

Color harmonies
HarmonyRotationColor
Complementary+180°#445c00
Analogous−30°, +30°#3733c6#900082
Triadic+120°, +240°#7e3f00#006358
Split-complementary+150°, +210°#664f00#00662a

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 purple-800 is a cool color: its hue is 275° 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
rebeccapurple#6633995.8
darkviolet#9400d39.2
darkmagenta#8b008b9.2

Nearest Tailwind v4 colors

Nearest Tailwind v4 colors
ColorHEXΔE OK
violet-800#5d0ec04.6
purple-900#59168b7.1
violet-900#4d179a7.4

Code snippets

Tailwind CSS
<div class="bg-purple-800 text-white">...</div>
<p class="text-purple-800 border-purple-800">...</p>
CSS
.element {
  color: var(--color-purple-800);
  background-color: oklch(43.8% 0.218 303.724);
  border-color: #6e11b0;
  outline-color: rgb(110 17 176);
}
SwiftUI
import SwiftUI

extension Color {
  static let purple800 = Color(red: 0.431, green: 0.067, blue: 0.690)
}
Jetpack Compose
import androidx.compose.ui.graphics.Color

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

const purple800 = Color(0xFF6E11B0);
Android XML
<!-- res/values/colors.xml -->
<color name="purple_800">#6E11B0</color>

Frequently asked questions

What is the hex code for Tailwind purple-800?
In Tailwind CSS v4, purple-800 is oklch(43.8% 0.218 303.724), which converts to #6E11B0 (rgb(110, 17, 176)) in sRGB. In Tailwind v3 the same name was #6B21A8.
What is the difference between purple-800 in Tailwind v3 and v4?
v3 used the hex #6B21A8; v4 redefined the palette in OKLCH as oklch(43.8% 0.218 303.724). In v3, purple-800 was #6B21A8. The v4 value is ΔE OK 2.0 away, below the point where most people can tell them apart; v4 is more saturated.
How do I use purple-800 in plain CSS?
Tailwind v4 defines every palette color as a theme variable, so in CSS you write var(--color-purple-800). By default Tailwind only emits the variables your project uses; @theme static emits all of them.
Can you use white text on purple-800?
White text on purple-800 has a contrast ratio of 8.86:1, which passes both AA and AAA under WCAG 2.2. Black text reaches 2.37:1 and fails AA even for large text. In APCA terms that is Lc −93.2 for white and Lc 15.4 for black.
Which CSS named color is closest to purple-800?
The closest is rebeccapurple (#663399) at ΔE OK 5.8, followed by darkviolet and darkmagenta.

Last reviewed by Arielton Oberek.