#31338D#31338D

#31338D is a dark, vivid blue. Relative luminance 0.049; OKLCH L 37.9% C 0.146 H 275.9°. Best body text is #FFFFFF at 10.56:1 contrast (WCAG AA passes).

Color values

HEX#31338D
RGBrgb(49, 51, 141)
HSLhsl(239, 48%, 37%)
HSVhsv(239, 65%, 55%)
CMYKcmyk(65.2%, 63.8%, 0%, 44.7%)
CIE-LABlab(26.57, 28.61, -50.31)
CIE-LCHlch(26.57, 57.87, 299.63°)
OKLaboklab(37.86% 0.0151 -0.1449)
OKLCHoklch(37.86% 0.146 275.9)
XYZxyz(7.2566, 4.9431, 25.7658)
Luminance0.0494 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#31338D #8D8B31
analogous
#31618D #31338D #5D318D
triadic
#31338D #8D3133 #338D31
tetradic
#31338D #8D3161 #8D8B31 #318D5D
square
#31338D #8D3161 #8D8B31 #318D5D
split-complementary
#31338D #8D5D31 #618D31
monochromatic
#111232 #212360 #31338D #4143BA #6C6ECC

Accessibility & contrast

On white

10.56
#31338D on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.99
#31338D on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #31338D
10.56:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##31338D#FFFFFF#000000##FFFFFF
##31338D1.0010.561.9910.56
#FFFFFF10.561.0021.001.00
#0000001.9921.001.0021.00
##FFFFFF10.561.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004390
Deuteranopia (green-blind)
#003B8B
Tritanopia (blue-blind)
#004A5B
Achromatopsia (no color)
#3F3F3F

Design tokens & code

CSS
--color: #31338d;
/* rgb */ color: rgb(49, 51, 141);
/* oklch */ color: oklch(37.9% 0.146 275.9);
Tailwind
colors: {
  custom: {
    50: '#746baf',
    500: '#31338d',
    950: '#000000',
  },
}
SCSS
$custom: #31338d;
$custom-light: #746baf;
$custom-dark: #000000;
JSON
{
  "hex": "#31338d",
  "rgb": {
    "r": 49,
    "g": 51,
    "b": 141
  },
  "hsl": {
    "h": 238.696,
    "s": 48.421,
    "l": 37.255
  },
  "oklch": {
    "l": 0.37864,
    "c": 0.1457,
    "h": 275.9
  },
  "luminance": 0.04944
}

Semantic roles & 50–950 ramp

primary
#31338D
secondary
#B4B266
accent
#D550D8
background
#F7F6FA
surface
#EDEBF5
border
#C8C6CF
text
#090610
muted
#7B7A7F

Preview Lab

Preview with #31338D

Body copy rendered with the generated semantic roles for this colour.

Preview Lab → · Contrast checker → · Palette generator →

#31338D Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva