Skip to content

Tailwind CSS v4 default palette

Tailwind blue-300: #8EC5FF

In Tailwind CSS v4, blue-300 is defined as --color-blue-300: oklch(80.9% 0.105 251.813), which is #8EC5FF in hex and rgb(142, 197, 255): a very light, moderately saturated sky blue. In Tailwind v3, blue-300 was #93C5FD.

blue-300#8EC5FF

In OKLCH, blue-300 has a lightness of 80.9%, chroma 0.105 and hue 251.8°.

This OKLCH value lies outside sRGB. The hex #8EC5FF 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.6026 0.7672 0.9939).

In v3, blue-300 was #93C5FD. The v4 value is ΔE OK 0.9 away, below the point where most people can tell them apart; v4 is more saturated.

Tailwind blue is the default for links, focus rings and primary buttons in many projects built on the framework.

Color codes for blue-300

Color codes for blue-300
Tailwind v4 token--color-blue-300
OKLCH (source value)oklch(80.9% 0.105 251.813)
HEX#8EC5FF
RGBrgb(142, 197, 255)
HSLhsl(211, 100%, 78%)
HWBhwb(211 56% 0%)
CMYK (naive, no ICC profile)cmyk(44%, 23%, 0%, 0%)
Decimal9,356,799
Display P3color(display-p3 0.6026 0.7672 0.9939)
Tailwind v3 hex#93C5FD
Utility classesbg-blue-300, text-blue-300, border-blue-300

Tailwind blue scale

Contrast and accessibility

On blue-300, black text has a contrast ratio of 11.58:1 and passes AAA at any text size; white text reaches 1.81: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 blue-30011.58:1PassPassPassPass70.2
White text on blue-3001.81:1FailFailFailFail−37.8
Blue-300 text on white1.81:1FailFailFailFail33.7
Blue-300 text on black11.58:1PassPassPassPass−68.9

Tints and shades

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

Tints (mixed with white)

  1. 5%
    #94c8ff
  2. 15%
    #9fceff
  3. 25%
    #aad4ff
  4. 35%
    #b6d9ff
  5. 45%
    #c1dfff
  6. 55%
    #cce5ff
  7. 65%
    #d7ebff
  8. 75%
    #e3f1ff
  9. 85%
    #eef6ff
  10. 95%
    #f9fcff

Shades (mixed with black)

  1. 5%
    #87bbf2
  2. 15%
    #79a7d9
  3. 25%
    #6b94bf
  4. 35%
    #5c80a6
  5. 45%
    #4e6c8c
  6. 55%
    #405973
  7. 65%
    #324559
  8. 75%
    #243140
  9. 85%
    #151e26
  10. 95%
    #070a0d

Color harmonies

Rotating the hue in OKLCH while keeping lightness and chroma, blue-300's complementary color is #EBB572 (close to burlywood), its analogous colors are #6BD0F1 and #B5B9FF, and its triadic partners are #FCA4AF and #A8CF87. For text on top, black gives the higher contrast.

Color harmonies
HarmonyRotationColor
Complementary+180°#ebb572
Analogous−30°, +30°#6bd0f1#b5b9ff
Triadic+120°, +240°#fca4af#a8cf87
Split-complementary+150°, +210°#fbaa8b#cec371

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 blue-300 is a cool color: its hue is 211° 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
lightskyblue#87cefa3.0
skyblue#87ceeb4.8
lightsteelblue#b0c4de6.2

Nearest Tailwind v4 colors

Nearest Tailwind v4 colors
ColorHEXΔE OK
sky-300#74d4ff4.5
indigo-300#a3b3ff5.1
violet-300#c4b4ff7.7

Code snippets

Tailwind CSS
<div class="bg-blue-300 text-black">...</div>
<p class="text-blue-300 border-blue-300">...</p>
CSS
.element {
  color: var(--color-blue-300);
  background-color: oklch(80.9% 0.105 251.813);
  border-color: #8ec5ff;
  outline-color: rgb(142 197 255);
}
SwiftUI
import SwiftUI

extension Color {
  static let blue300 = Color(red: 0.557, green: 0.773, blue: 1.000)
}
Jetpack Compose
import androidx.compose.ui.graphics.Color

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

const blue300 = Color(0xFF8EC5FF);
Android XML
<!-- res/values/colors.xml -->
<color name="blue_300">#8EC5FF</color>

Frequently asked questions

What is the hex code for Tailwind blue-300?
In Tailwind CSS v4, blue-300 is oklch(80.9% 0.105 251.813), which converts to #8EC5FF (rgb(142, 197, 255)) in sRGB after gamut mapping, because the OKLCH value is outside sRGB. In Tailwind v3 the same name was #93C5FD.
What is the difference between blue-300 in Tailwind v3 and v4?
v3 used the hex #93C5FD; v4 redefined the palette in OKLCH as oklch(80.9% 0.105 251.813). In v3, blue-300 was #93C5FD. The v4 value is ΔE OK 0.9 away, below the point where most people can tell them apart; v4 is more saturated.
How do I use blue-300 in plain CSS?
Tailwind v4 defines every palette color as a theme variable, so in CSS you write var(--color-blue-300). By default Tailwind only emits the variables your project uses; @theme static emits all of them.
Can you use white text on blue-300?
White text on blue-300 has a contrast ratio of 1.81:1, which fails AA even for large text under WCAG 2.2. Black text reaches 11.58:1 and passes both AA and AAA. In APCA terms that is Lc −37.8 for white and Lc 70.2 for black.
Which CSS named color is closest to blue-300?
The closest is lightskyblue (#87CEFA) at ΔE OK 3.0, followed by skyblue and lightsteelblue.

Last reviewed by Arielton Oberek.