Tailwind CSS v4 default palette
Tailwind mauve-800: #2A212C
In Tailwind CSS v4, mauve-800 is defined as --color-mauve-800: oklch(26.3% 0.024 320.12), which is #2A212C in hex and rgb(42, 33, 44): a very dark, grayish purple.
In OKLCH, mauve-800 has a lightness of 26.3%, chroma 0.024 and hue 320.1°.
The value fits inside sRGB, so the hex #2A212C represents it without loss on any screen.
Tailwind mauve is one of four tinted neutral scales added in Tailwind CSS v4.2: a gray with a purple-pink cast. It has no v3 equivalent.
Color codes for mauve-800
| Tailwind v4 token | --color-mauve-800 |
|---|---|
| OKLCH (source value) | oklch(26.3% 0.024 320.12) |
| HEX | #2A212C |
| RGB | rgb(42, 33, 44) |
| HSL | hsl(289, 14%, 15%) |
| HWB | hwb(289 13% 83%) |
| CMYK (naive, no ICC profile) | cmyk(5%, 25%, 0%, 83%) |
| Decimal | 2,761,004 |
| Utility classes | bg-mauve-800, text-mauve-800, border-mauve-800 |
Tailwind mauve scale
Contrast and accessibility
On mauve-800, white text has a contrast ratio of 15.52:1 and passes AAA at any text size; black text reaches 1.35: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.
| Pair | Ratio | AA | AA large | AAA | AAA large | APCA Lc |
|---|---|---|---|---|---|---|
| Black text on mauve-800 | 1.35:1 | Fail | Fail | Fail | Fail | 0.0 |
| White text on mauve-800 | 15.52:1 | Pass | Pass | Pass | Pass | −105.1 |
| Mauve-800 text on white | 15.52:1 | Pass | Pass | Pass | Pass | 102.5 |
| Mauve-800 text on black | 1.35:1 | Fail | Fail | Fail | Fail | 0.0 |
Tints and shades
Each step mixes var(--color-mauve-800) with white (tints) or black (shades) in gamma-encoded sRGB, the same result as color-mix(in srgb, var(--color-mauve-800), white 25%) in CSS.
Tints (mixed with white)
- 5%
#352c37 - 15%
#4a424c - 25%
#5f5961 - 35%
#756f76 - 45%
#8a858b - 55%
#9f9ba0 - 65%
#b4b1b5 - 75%
#cac8ca - 85%
#dfdedf - 95%
#f4f4f4
Shades (mixed with black)
- 5%
#281f2a - 15%
#241c25 - 25%
#201921 - 35%
#1b151d - 45%
#171218 - 55%
#130f14 - 65%
#0f0c0f - 75%
#0b080b - 85%
#060507 - 95%
#020202
Color harmonies
Rotating the hue in OKLCH while keeping lightness and chroma, mauve-800's complementary color is #1F281D (close to darkslategray), its analogous colors are #242330 and #2E2026, and its triadic partners are #2B2417 and #162829. For text on top, white gives the higher contrast.
| Harmony | Rotation | Color |
|---|---|---|
| Complementary | +180° | #1f281d |
| Analogous | −30°, +30° | #242330#2e2026 |
| Triadic | +120°, +240° | #2b2417#162829 |
| Split-complementary | +150°, +210° | #252618#192923 |
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 mauve-800 is close to neutral: its OKLCH chroma is only 0.024, so its temperature comes from context. The faint 289° hue gives it a slightly cool cast.
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
| Color | HEX | ΔE OK |
|---|---|---|
| midnightblue | #191970 | 13.1 |
| darkslategray | #2f4f4f | 15.0 |
| indigo | #4b0082 | 17.4 |
Code snippets
<div class="bg-mauve-800 text-white">...</div>
<p class="text-mauve-800 border-mauve-800">...</p>.element {
color: var(--color-mauve-800);
background-color: oklch(26.3% 0.024 320.12);
border-color: #2a212c;
outline-color: rgb(42 33 44);
}import SwiftUI
extension Color {
static let mauve800 = Color(red: 0.165, green: 0.129, blue: 0.173)
}import androidx.compose.ui.graphics.Color
val Mauve800 = Color(0xFF2A212C)import 'package:flutter/material.dart';
const mauve800 = Color(0xFF2A212C);<!-- res/values/colors.xml -->
<color name="mauve_800">#2A212C</color>Frequently asked questions
- What is the hex code for Tailwind mauve-800?
- In Tailwind CSS v4, mauve-800 is oklch(26.3% 0.024 320.12), which converts to #2A212C (rgb(42, 33, 44)) in sRGB.
- Is mauve-800 available in Tailwind v3?
- No. The mauve scale was added in Tailwind CSS v4.2. In v3 you can recreate it in tailwind.config.js under theme.extend.colors with the hex #2A212C.
- How do I use mauve-800 in plain CSS?
- Tailwind v4 defines every palette color as a theme variable, so in CSS you write var(--color-mauve-800). By default Tailwind only emits the variables your project uses; @theme static emits all of them.
- Can you use white text on mauve-800?
- White text on mauve-800 has a contrast ratio of 15.52:1, which passes both AA and AAA under WCAG 2.2. Black text reaches 1.35:1 and fails AA even for large text. In APCA terms that is Lc −105.1 for white and Lc 0.0 for black.
- Which CSS named color is closest to mauve-800?
- The closest is midnightblue (#191970) at ΔE OK 13.1, followed by darkslategray and indigo.
Last reviewed by Arielton Oberek.