#31398E#31398E

#31398E is a dark, vivid blue. Relative luminance 0.055; OKLCH L 39.1% C 0.139 H 273.9°. Best body text is #FFFFFF at 9.97:1 contrast (WCAG AA passes).

Color values

HEX#31398E
RGBrgb(49, 57, 142)
HSLhsl(235, 49%, 37%)
HSVhsv(235, 65%, 56%)
CMYKcmyk(65.5%, 59.9%, 0%, 44.3%)
CIE-LABlab(28.20, 25.00, -48.28)
CIE-LCHlch(28.20, 54.36, 297.37°)
OKLaboklab(39.09% 0.0096 -0.1389)
OKLCHoklch(39.09% 0.139 273.9)
XYZxyz(7.6106, 5.5316, 26.2526)
Luminance0.0553 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#31398E #8E8631
analogous
#31678E #31398E #58318E
triadic
#31398E #8E3139 #398E31
tetradic
#31398E #8E3167 #8E8631 #318E58
square
#31398E #8E3167 #8E8631 #318E58
split-complementary
#31398E #8E5831 #678E31
monochromatic
#121433 #212761 #31398E #414BBB #6D75CD

Accessibility & contrast

On white

9.97
#31398E on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.11
#31398E on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #31398E
9.97:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##31398E#FFFFFF#000000##FFFFFF
##31398E1.009.972.119.97
#FFFFFF9.971.0021.001.00
#0000002.1121.001.0021.00
##FFFFFF9.971.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004791
Deuteranopia (green-blind)
#003F8C
Tritanopia (blue-blind)
#004E5D
Achromatopsia (no color)
#434343

Design tokens & code

CSS
--color: #31398e;
/* rgb */ color: rgb(49, 57, 142);
/* oklch */ color: oklch(39.1% 0.139 273.9);
Tailwind
colors: {
  custom: {
    50: '#746fb0',
    500: '#31398e',
    950: '#000000',
  },
}
SCSS
$custom: #31398e;
$custom-light: #746fb0;
$custom-dark: #000000;
JSON
{
  "hex": "#31398e",
  "rgb": {
    "r": 49,
    "g": 57,
    "b": 142
  },
  "hsl": {
    "h": 234.839,
    "s": 48.691,
    "l": 37.451
  },
  "oklch": {
    "l": 0.39091,
    "c": 0.13923,
    "h": 273.9
  },
  "luminance": 0.05532
}

Semantic roles & 50–950 ramp

primary
#31398E
secondary
#B4AD67
accent
#CC50D8
background
#F7F6FA
surface
#EDECF5
border
#C8C7CF
text
#090710
muted
#7B7A7F

Preview Lab

Preview with #31398E

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

Preview Lab → · Contrast checker → · Palette generator →

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