#31397F#31397F

#31397F is a dark, moderate blue. Relative luminance 0.051; OKLCH L 37.9% C 0.117 H 274.5°. Best body text is #FFFFFF at 10.38:1 contrast (WCAG AA passes).

Color values

HEX#31397F
RGBrgb(49, 57, 127)
HSLhsl(234, 44%, 35%)
HSVhsv(234, 61%, 50%)
CMYKcmyk(61.4%, 55.1%, 0%, 50.2%)
CIE-LABlab(27.05, 19.53, -40.81)
CIE-LCHlch(27.05, 45.24, 295.58°)
OKLaboklab(37.87% 0.0091 -0.1169)
OKLCHoklch(37.87% 0.117 274.5)
XYZxyz(6.5593, 5.1110, 20.7154)
Luminance0.0511 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#31397F #7F7731
analogous
#31607F #31397F #50317F
triadic
#31397F #7F3139 #397F31
tetradic
#31397F #7F3160 #7F7731 #317F50
square
#31397F #7F3160 #7F7731 #317F50
split-complementary
#31397F #7F5031 #607F31
monochromatic
#0F1127 #202553 #31397F #424DAB #6670C4

Accessibility & contrast

On white

10.38
#31397F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.02
#31397F on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #31397F
10.38:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##31397F#FFFFFF#000000##FFFFFF
##31397F1.0010.382.0210.38
#FFFFFF10.381.0021.001.00
#0000002.0221.001.0021.00
##FFFFFF10.381.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0E4381
Deuteranopia (green-blind)
#003D7E
Tritanopia (blue-blind)
#004956
Achromatopsia (no color)
#404040

Design tokens & code

CSS
--color: #31397f;
/* rgb */ color: rgb(49, 57, 127);
/* oklch */ color: oklch(37.9% 0.117 274.5);
Tailwind
colors: {
  custom: {
    50: '#716fa5',
    500: '#31397f',
    950: '#000000',
  },
}
SCSS
$custom: #31397f;
$custom-light: #716fa5;
$custom-dark: #000000;
JSON
{
  "hex": "#31397f",
  "rgb": {
    "r": 49,
    "g": 57,
    "b": 127
  },
  "hsl": {
    "h": 233.846,
    "s": 44.318,
    "l": 34.51
  },
  "oklch": {
    "l": 0.37869,
    "c": 0.11728,
    "h": 274.5
  },
  "luminance": 0.05112
}

Semantic roles & 50–950 ramp

primary
#31397F
secondary
#ABA460
accent
#C754D4
background
#F7F6FA
surface
#EDECF4
border
#C8C7CE
text
#08070F
muted
#7B7A7F

Preview Lab

Preview with #31397F

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

Preview Lab → · Contrast checker → · Palette generator →

#31397F Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva