#313FA8#313FA8

#313FA8 is a dark, vivid blue. Relative luminance 0.070; OKLCH L 42.5% C 0.168 H 271.4°. Best body text is #FFFFFF at 8.72:1 contrast (WCAG AA passes).

Color values

HEX#313FA8
RGBrgb(49, 63, 168)
HSLhsl(233, 55%, 43%)
HSVhsv(233, 71%, 66%)
CMYKcmyk(70.8%, 62.5%, 0%, 34.1%)
CIE-LABlab(31.88, 30.50, -58.08)
CIE-LCHlch(31.88, 65.61, 297.71°)
OKLaboklab(42.49% 0.0041 -0.1676)
OKLCHoklch(42.49% 0.168 271.4)
XYZxyz(10.1096, 7.0341, 37.8631)
Luminance0.0703 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#313FA8 #A89A31
analogous
#317BA8 #313FA8 #5E31A8
triadic
#313FA8 #A8313F #3FA831
tetradic
#313FA8 #A8317B #A89A31 #31A85E
square
#313FA8 #A8317B #A89A31 #31A85E
split-complementary
#313FA8 #A85E31 #7BA831
monochromatic
#151B49 #232D79 #313FA8 #4C5ACB #7B86D8

Accessibility & contrast

On white

8.72
#313FA8 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.41
#313FA8 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #313FA8
8.72:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##313FA8#FFFFFF#000000##FFFFFF
##313FA81.008.722.418.72
#FFFFFF8.721.0021.001.00
#0000002.4121.001.0021.00
##FFFFFF8.721.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0051AB
Deuteranopia (green-blind)
#0046A6
Tritanopia (blue-blind)
#005A6D
Achromatopsia (no color)
#4B4B4B

Design tokens & code

CSS
--color: #313fa8;
/* rgb */ color: rgb(49, 63, 168);
/* oklch */ color: oklch(42.5% 0.168 271.4);
Tailwind
colors: {
  custom: {
    50: '#7974c3',
    500: '#313fa8',
    950: '#000000',
  },
}
SCSS
$custom: #313fa8;
$custom-light: #7974c3;
$custom-dark: #000000;
JSON
{
  "hex": "#313fa8",
  "rgb": {
    "r": 49,
    "g": 63,
    "b": 168
  },
  "hsl": {
    "h": 232.941,
    "s": 54.839,
    "l": 42.549
  },
  "oklch": {
    "l": 0.42488,
    "c": 0.16769,
    "h": 271.4
  },
  "luminance": 0.07035
}

Semantic roles & 50–950 ramp

primary
#313FA8
secondary
#C1B874
accent
#CD4ADE
background
#F8F7FC
surface
#EFEDF8
border
#CAC8D1
text
#0A0813
muted
#7C7B82

Preview Lab

Preview with #313FA8

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

Preview Lab → · Contrast checker → · Palette generator →

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