#312DB8#312DB8

#312DB8 is a dark, highly saturated blue. Relative luminance 0.060; OKLCH L 41.1% C 0.208 H 273.6°. Best body text is #FFFFFF at 9.55:1 contrast (WCAG AA passes).

Color values

HEX#312DB8
RGBrgb(49, 45, 184)
HSLhsl(242, 61%, 45%)
HSVhsv(242, 76%, 72%)
CMYKcmyk(73.4%, 75.5%, 0%, 27.8%)
CIE-LABlab(29.39, 46.95, -71.74)
CIE-LCHlch(29.39, 85.73, 303.21°)
OKLaboklab(41.14% 0.013 -0.2075)
OKLCHoklch(41.14% 0.208 273.6)
XYZxyz(10.8539, 5.9893, 45.9221)
Luminance0.0599 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#312DB8 #B4B82D
analogous
#2D6EB8 #312DB8 #772DB8
triadic
#312DB8 #B8312D #2DB831
tetradic
#312DB8 #B82D6E #B4B82D #2DB877
square
#312DB8 #B82D6E #B4B82D #2DB877
split-complementary
#312DB8 #B8772D #6EB82D
monochromatic
#171556 #242187 #312DB8 #524ED4 #8280E0

Accessibility & contrast

On white

9.55
#312DB8 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.20
#312DB8 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #312DB8
9.55:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##312DB8#FFFFFF#000000##FFFFFF
##312DB81.009.552.209.55
#FFFFFF9.551.0021.001.00
#0000002.2021.001.0021.00
##FFFFFF9.551.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004CBC
Deuteranopia (green-blind)
#003FB6
Tritanopia (blue-blind)
#005671
Achromatopsia (no color)
#454545

Design tokens & code

CSS
--color: #312db8;
/* rgb */ color: rgb(49, 45, 184);
/* oklch */ color: oklch(41.1% 0.208 273.6);
Tailwind
colors: {
  custom: {
    50: '#7f68cf',
    500: '#312db8',
    950: '#000000',
  },
}
SCSS
$custom: #312db8;
$custom-light: #7f68cf;
$custom-dark: #000000;
JSON
{
  "hex": "#312db8",
  "rgb": {
    "r": 49,
    "g": 45,
    "b": 184
  },
  "hsl": {
    "h": 241.727,
    "s": 60.699,
    "l": 44.902
  },
  "oklch": {
    "l": 0.41142,
    "c": 0.20795,
    "h": 273.6
  },
  "luminance": 0.0599
}

Semantic roles & 50–950 ramp

primary
#312DB8
secondary
#C6C978
accent
#E444DF
background
#F8F6FC
surface
#F0EBF9
border
#CBC6D2
text
#0C0614
muted
#7D7A82

Preview Lab

Preview with #312DB8

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

Preview Lab → · Contrast checker → · Palette generator →

#312DB8 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva