#313AA5#313AA5

#313AA5 is a dark, vivid blue. Relative luminance 0.064; OKLCH L 41.3% C 0.170 H 272.7°. Best body text is #FFFFFF at 9.21:1 contrast (WCAG AA passes).

Color values

HEX#313AA5
RGBrgb(49, 58, 165)
HSLhsl(235, 54%, 42%)
HSVhsv(235, 70%, 65%)
CMYKcmyk(70.3%, 64.8%, 0%, 35.3%)
CIE-LABlab(30.39, 32.66, -58.73)
CIE-LCHlch(30.39, 67.19, 299.08°)
OKLaboklab(41.31% 0.008 -0.1696)
OKLCHoklch(41.31% 0.17 272.7)
XYZxyz(9.5689, 6.3948, 36.3200)
Luminance0.0640 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#313AA5 #A59C31
analogous
#3174A5 #313AA5 #6231A5
triadic
#313AA5 #A5313A #3AA531
tetradic
#313AA5 #A53174 #A59C31 #31A562
square
#313AA5 #A53174 #A59C31 #31A562
split-complementary
#313AA5 #A56231 #74A531
monochromatic
#151947 #232976 #313AA5 #4A54C9 #7980D7

Accessibility & contrast

On white

9.21
#313AA5 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.28
#313AA5 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #313AA5
9.21:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##313AA5#FFFFFF#000000##FFFFFF
##313AA51.009.212.289.21
#FFFFFF9.211.0021.001.00
#0000002.2821.001.0021.00
##FFFFFF9.211.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004DA8
Deuteranopia (green-blind)
#0042A3
Tritanopia (blue-blind)
#00566A
Achromatopsia (no color)
#484848

Design tokens & code

CSS
--color: #313aa5;
/* rgb */ color: rgb(49, 58, 165);
/* oklch */ color: oklch(41.3% 0.170 272.7);
Tailwind
colors: {
  custom: {
    50: '#7970c1',
    500: '#313aa5',
    950: '#000000',
  },
}
SCSS
$custom: #313aa5;
$custom-light: #7970c1;
$custom-dark: #000000;
JSON
{
  "hex": "#313aa5",
  "rgb": {
    "r": 49,
    "g": 58,
    "b": 165
  },
  "hsl": {
    "h": 235.345,
    "s": 54.206,
    "l": 41.961
  },
  "oklch": {
    "l": 0.41307,
    "c": 0.16976,
    "h": 272.7
  },
  "luminance": 0.06396
}

Semantic roles & 50–950 ramp

primary
#313AA5
secondary
#C0BA72
accent
#D24ADE
background
#F7F6FC
surface
#EEECF8
border
#C9C7D1
text
#0A0712
muted
#7C7A81

Preview Lab

Preview with #313AA5

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

Preview Lab → · Contrast checker → · Palette generator →

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