#313A9E#313A9E

#313A9E is a dark, vivid blue. Relative luminance 0.061; OKLCH L 40.7% C 0.160 H 273.0°. Best body text is #FFFFFF at 9.42:1 contrast (WCAG AA passes).

Color values

HEX#313A9E
RGBrgb(49, 58, 158)
HSLhsl(235, 53%, 41%)
HSVhsv(235, 69%, 62%)
CMYKcmyk(69%, 63.3%, 0%, 38%)
CIE-LABlab(29.78, 30.14, -55.49)
CIE-LCHlch(29.78, 63.14, 298.51°)
OKLaboklab(40.67% 0.0083 -0.1601)
OKLCHoklch(40.67% 0.16 273)
XYZxyz(8.9492, 6.1469, 33.0560)
Luminance0.0615 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#313A9E #9E9531
analogous
#31709E #313A9E #5E319E
triadic
#313A9E #9E313A #3A9E31
tetradic
#313A9E #9E3170 #9E9531 #319E5E
square
#313A9E #9E3170 #9E9531 #319E5E
split-complementary
#313A9E #9E5E31 #709E31
monochromatic
#141841 #23296F #313A9E #4651C6 #757DD4

Accessibility & contrast

On white

9.42
#313A9E on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.23
#313A9E on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #313A9E
9.42:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##313A9E#FFFFFF#000000##FFFFFF
##313A9E1.009.422.239.42
#FFFFFF9.421.0021.001.00
#0000002.2321.001.0021.00
##FFFFFF9.421.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004BA1
Deuteranopia (green-blind)
#00419C
Tritanopia (blue-blind)
#005366
Achromatopsia (no color)
#464646

Design tokens & code

CSS
--color: #313a9e;
/* rgb */ color: rgb(49, 58, 158);
/* oklch */ color: oklch(40.7% 0.160 273.0);
Tailwind
colors: {
  custom: {
    50: '#7870bc',
    500: '#313a9e',
    950: '#000000',
  },
}
SCSS
$custom: #313a9e;
$custom-light: #7870bc;
$custom-dark: #000000;
JSON
{
  "hex": "#313a9e",
  "rgb": {
    "r": 49,
    "g": 58,
    "b": 158
  },
  "hsl": {
    "h": 235.046,
    "s": 52.657,
    "l": 40.588
  },
  "oklch": {
    "l": 0.40673,
    "c": 0.16029,
    "h": 273
  },
  "luminance": 0.06148
}

Semantic roles & 50–950 ramp

primary
#313A9E
secondary
#BCB66E
accent
#D04CDC
background
#F7F6FB
surface
#EEECF6
border
#C9C7D0
text
#0A0712
muted
#7C7A81

Preview Lab

Preview with #313A9E

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

Preview Lab → · Contrast checker → · Palette generator →

#313A9E Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva