#312BA5#312BA5

#312BA5 is a dark, vivid blue. Relative luminance 0.051; OKLCH L 38.9% C 0.187 H 275.5°. Best body text is #FFFFFF at 10.40:1 contrast (WCAG AA passes).

Color values

HEX#312BA5
RGBrgb(49, 43, 165)
HSLhsl(243, 59%, 41%)
HSVhsv(243, 74%, 65%)
CMYKcmyk(70.3%, 73.9%, 0%, 35.3%)
CIE-LABlab(27.01, 41.84, -64.28)
CIE-LCHlch(27.01, 76.69, 303.06°)
OKLaboklab(38.87% 0.0178 -0.1858)
OKLCHoklch(38.87% 0.187 275.5)
XYZxyz(8.9198, 5.0965, 36.1037)
Luminance0.0510 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#312BA5 #9FA52B
analogous
#2B62A5 #312BA5 #6E2BA5
triadic
#312BA5 #A5312B #2BA531
tetradic
#312BA5 #A52B62 #9FA52B #2BA56E
square
#312BA5 #A52B62 #9FA52B #2BA56E
split-complementary
#312BA5 #A56E2B #62A52B
monochromatic
#141244 #231E74 #312BA5 #4740CD #7671DA

Accessibility & contrast

On white

10.40
#312BA5 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.02
#312BA5 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #312BA5
10.40:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##312BA5#FFFFFF#000000##FFFFFF
##312BA51.0010.402.0210.40
#FFFFFF10.401.0021.001.00
#0000002.0221.001.0021.00
##FFFFFF10.401.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0045A9
Deuteranopia (green-blind)
#003AA3
Tritanopia (blue-blind)
#004E65
Achromatopsia (no color)
#404040

Design tokens & code

CSS
--color: #312ba5;
/* rgb */ color: rgb(49, 43, 165);
/* oklch */ color: oklch(38.9% 0.187 275.5);
Tailwind
colors: {
  custom: {
    50: '#7a66c1',
    500: '#312ba5',
    950: '#000000',
  },
}
SCSS
$custom: #312ba5;
$custom-light: #7a66c1;
$custom-dark: #000000;
JSON
{
  "hex": "#312ba5",
  "rgb": {
    "r": 49,
    "g": 43,
    "b": 165
  },
  "hsl": {
    "h": 242.951,
    "s": 58.654,
    "l": 40.784
  },
  "oklch": {
    "l": 0.38868,
    "c": 0.18666,
    "h": 275.5
  },
  "luminance": 0.05097
}

Semantic roles & 50–950 ramp

primary
#312BA5
secondary
#BDC16B
accent
#E246DA
background
#F8F6FC
surface
#EFEBF8
border
#CAC6D1
text
#0B0612
muted
#7C7A81

Preview Lab

Preview with #312BA5

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

Preview Lab → · Contrast checker → · Palette generator →

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