#313D98#313D98

#313D98 is a dark, vivid blue. Relative luminance 0.063; OKLCH L 40.7% C 0.148 H 272.3°. Best body text is #FFFFFF at 9.33:1 contrast (WCAG AA passes).

Color values

HEX#313D98
RGBrgb(49, 61, 152)
HSLhsl(233, 51%, 39%)
HSVhsv(233, 68%, 60%)
CMYKcmyk(67.8%, 59.9%, 0%, 40.4%)
CIE-LABlab(30.05, 25.98, -51.40)
CIE-LCHlch(30.05, 57.59, 296.82°)
OKLaboklab(40.72% 0.006 -0.148)
OKLCHoklch(40.72% 0.148 272.3)
XYZxyz(8.6010, 6.2567, 30.4541)
Luminance0.0626 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#313D98 #988C31
analogous
#317198 #313D98 #593198
triadic
#313D98 #98313D #3D9831
tetradic
#313D98 #983171 #988C31 #319859
square
#313D98 #983171 #988C31 #319859
split-complementary
#313D98 #985931 #719831
monochromatic
#13183B #222A6A #313D98 #4452C3 #727DD2

Accessibility & contrast

On white

9.33
#313D98 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.25
#313D98 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #313D98
9.33:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##313D98#FFFFFF#000000##FFFFFF
##313D981.009.332.259.33
#FFFFFF9.331.0021.001.00
#0000002.2521.001.0021.00
##FFFFFF9.331.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004C9B
Deuteranopia (green-blind)
#004296
Tritanopia (blue-blind)
#005364
Achromatopsia (no color)
#474747

Design tokens & code

CSS
--color: #313d98;
/* rgb */ color: rgb(49, 61, 152);
/* oklch */ color: oklch(40.7% 0.148 272.3);
Tailwind
colors: {
  custom: {
    50: '#7672b7',
    500: '#313d98',
    950: '#000000',
  },
}
SCSS
$custom: #313d98;
$custom-light: #7672b7;
$custom-dark: #000000;
JSON
{
  "hex": "#313d98",
  "rgb": {
    "r": 49,
    "g": 61,
    "b": 152
  },
  "hsl": {
    "h": 233.01,
    "s": 51.244,
    "l": 39.412
  },
  "oklch": {
    "l": 0.40718,
    "c": 0.14815,
    "h": 272.3
  },
  "luminance": 0.06257
}

Semantic roles & 50–950 ramp

primary
#313D98
secondary
#B9B06B
accent
#CA4DDB
background
#F7F6FB
surface
#EEECF6
border
#C9C7D0
text
#090811
muted
#7B7B80

Preview Lab

Preview with #313D98

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

Preview Lab → · Contrast checker → · Palette generator →

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