Skip to content

Tailwind CSS v4 default palette

Tailwind violet-50: #F5F3FF

In Tailwind CSS v4, violet-50 is defined as --color-violet-50: oklch(96.9% 0.016 293.756), which is #F5F3FF in hex and rgb(245, 243, 255): an off-white with a blue-violet tint. In Tailwind v3, violet-50 was #F5F3FF.

violet-50#F5F3FF

In OKLCH, violet-50 has a lightness of 96.9%, chroma 0.016 and hue 293.8°.

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

In v3, violet-50 was #F5F3FF. The v4 value is ΔE OK 0.0 away, below the point where most people can tell them apart.

Tailwind violet sits between indigo and purple, a popular choice for AI and creative-tool branding.

Color codes for violet-50

Color codes for violet-50
Tailwind v4 token--color-violet-50
OKLCH (source value)oklch(96.9% 0.016 293.756)
HEX#F5F3FF
RGBrgb(245, 243, 255)
HSLhsl(250, 100%, 98%)
HWBhwb(250 95% 0%)
CMYK (naive, no ICC profile)cmyk(4%, 5%, 0%, 0%)
Decimal16,118,783
Tailwind v3 hex#F5F3FF
Utility classesbg-violet-50, text-violet-50, border-violet-50

Tailwind violet scale

Contrast and accessibility

On violet-50, black text has a contrast ratio of 19.14:1 and passes AAA at any text size; white text reaches 1.09: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 violet-5019.14:1PassPassPassPass99.7
White text on violet-501.09:1FailFailFailFail0.0
Violet-50 text on white1.09:1FailFailFailFail0.0
Violet-50 text on black19.14:1PassPassPassPass−100.9

Tints and shades

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

Tints (mixed with white)

  1. 5%
    #f6f4ff
  2. 15%
    #f7f5ff
  3. 25%
    #f8f6ff
  4. 35%
    #f9f7ff
  5. 45%
    #faf8ff
  6. 55%
    #fbfaff
  7. 65%
    #fcfbff
  8. 75%
    #fdfcff
  9. 85%
    #fefdff
  10. 95%
    #fffeff

Shades (mixed with black)

  1. 5%
    #e9e7f2
  2. 15%
    #d0cfd9
  3. 25%
    #b8b6bf
  4. 35%
    #9f9ea6
  5. 45%
    #87868c
  6. 55%
    #6e6d73
  7. 65%
    #565559
  8. 75%
    #3d3d40
  9. 85%
    #252426
  10. 95%
    #0c0c0d

Color harmonies

Rotating the hue in OKLCH while keeping lightness and chroma, violet-50's complementary color is #F4F6EA (close to oldlace), its analogous colors are #EFF5FF and #FAF1FB, and its triadic partners are #FEF2EB and #EBF9F4. For text on top, black gives the higher contrast.

Color harmonies
HarmonyRotationColor
Complementary+180°#f4f6ea
Analogous−30°, +30°#eff5ff#faf1fb
Triadic+120°, +240°#fef2eb#ebf9f4
Split-complementary+150°, +210°#faf4e9#eff8ee

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 violet-50 is close to neutral: its OKLCH chroma is only 0.016, so its temperature comes from context. The faint 250° 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

Nearest CSS named colors
ColorHEXΔE OK
aliceblue#f0f8ff1.4
ghostwhite#f8f8ff1.4
whitesmoke#f5f5f51.6

Nearest Tailwind v4 colors

Nearest Tailwind v4 colors
ColorHEXΔE OK
purple-50#faf5ff0.9
indigo-50#eef2ff1.0
blue-50#eff6ff1.0

Code snippets

Tailwind CSS
<div class="bg-violet-50 text-black">...</div>
<p class="text-violet-50 border-violet-50">...</p>
CSS
.element {
  color: var(--color-violet-50);
  background-color: oklch(96.9% 0.016 293.756);
  border-color: #f5f3ff;
  outline-color: rgb(245 243 255);
}
SwiftUI
import SwiftUI

extension Color {
  static let violet50 = Color(red: 0.961, green: 0.953, blue: 1.000)
}
Jetpack Compose
import androidx.compose.ui.graphics.Color

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

const violet50 = Color(0xFFF5F3FF);
Android XML
<!-- res/values/colors.xml -->
<color name="violet_50">#F5F3FF</color>

Frequently asked questions

What is the hex code for Tailwind violet-50?
In Tailwind CSS v4, violet-50 is oklch(96.9% 0.016 293.756), which converts to #F5F3FF (rgb(245, 243, 255)) in sRGB. In Tailwind v3 the same name was #F5F3FF.
What is the difference between violet-50 in Tailwind v3 and v4?
v3 used the hex #F5F3FF; v4 redefined the palette in OKLCH as oklch(96.9% 0.016 293.756). In v3, violet-50 was #F5F3FF. The v4 value is ΔE OK 0.0 away, below the point where most people can tell them apart.
How do I use violet-50 in plain CSS?
Tailwind v4 defines every palette color as a theme variable, so in CSS you write var(--color-violet-50). By default Tailwind only emits the variables your project uses; @theme static emits all of them.
Can you use white text on violet-50?
White text on violet-50 has a contrast ratio of 1.09:1, which fails AA even for large text under WCAG 2.2. Black text reaches 19.14:1 and passes both AA and AAA. In APCA terms that is Lc 0.0 for white and Lc 99.7 for black.
Which CSS named color is closest to violet-50?
The closest is aliceblue (#F0F8FF) at ΔE OK 1.4, followed by ghostwhite and whitesmoke.

Last reviewed by Arielton Oberek.