#31317E#31317E

#31317E is a dark, vivid blue. Relative luminance 0.044; OKLCH L 36.2% C 0.127 H 278.0°. Best body text is #FFFFFF at 11.22:1 contrast (WCAG AA passes).

Color values

HEX#31317E
RGBrgb(49, 49, 126)
HSLhsl(240, 44%, 34%)
HSVhsv(240, 61%, 49%)
CMYKcmyk(61.1%, 61.1%, 0%, 50.6%)
CIE-LABlab(24.81, 24.59, -43.80)
CIE-LCHlch(24.81, 50.23, 299.31°)
OKLaboklab(36.18% 0.0176 -0.1258)
OKLCHoklch(36.18% 0.127 278)
XYZxyz(6.1296, 4.3555, 20.2523)
Luminance0.0436 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#31317E #7E7E31
analogous
#31587E #31317E #58317E
triadic
#31317E #7E3131 #317E31
tetradic
#31317E #7E3158 #7E7E31 #317E58
square
#31317E #7E3158 #7E7E31 #317E58
split-complementary
#31317E #7E5831 #587E31
monochromatic
#0F0F26 #202052 #31317E #4242AA #6666C3

Accessibility & contrast

On white

11.22
#31317E on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.87
#31317E on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #31317E
11.22:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##31317E#FFFFFF#000000##FFFFFF
##31317E1.0011.221.8711.22
#FFFFFF11.221.0021.001.00
#0000001.8721.001.0021.00
##FFFFFF11.221.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003E81
Deuteranopia (green-blind)
#00387C
Tritanopia (blue-blind)
#004452
Achromatopsia (no color)
#3B3B3B

Design tokens & code

CSS
--color: #31317e;
/* rgb */ color: rgb(49, 49, 126);
/* oklch */ color: oklch(36.2% 0.127 278.0);
Tailwind
colors: {
  custom: {
    50: '#7269a4',
    500: '#31317e',
    950: '#000000',
  },
}
SCSS
$custom: #31317e;
$custom-light: #7269a4;
$custom-dark: #000000;
JSON
{
  "hex": "#31317e",
  "rgb": {
    "r": 49,
    "g": 49,
    "b": 126
  },
  "hsl": {
    "h": 240,
    "s": 44,
    "l": 34.314
  },
  "oklch": {
    "l": 0.36179,
    "c": 0.12703,
    "h": 278
  },
  "luminance": 0.04356
}

Semantic roles & 50–950 ramp

primary
#31317E
secondary
#ABAB60
accent
#D454D4
background
#F7F6FA
surface
#EDEBF4
border
#C8C6CE
text
#08060F
muted
#7B7A7F

Preview Lab

Preview with #31317E

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

Preview Lab → · Contrast checker → · Palette generator →

#31317E Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva