#313161#313161

#313161 is a dark, moderate blue. Relative luminance 0.037; OKLCH L 33.9% C 0.083 H 281.1°. Best body text is #FFFFFF at 12.05:1 contrast (WCAG AA passes).

Color values

HEX#313161
RGBrgb(49, 49, 97)
HSLhsl(240, 33%, 29%)
HSVhsv(240, 49%, 38%)
CMYKcmyk(49.5%, 49.5%, 0%, 62%)
CIE-LABlab(22.70, 14.38, -28.59)
CIE-LCHlch(22.70, 32.01, 296.70°)
OKLaboklab(33.92% 0.0159 -0.0811)
OKLCHoklch(33.92% 0.083 281.1)
XYZxyz(4.5220, 3.7124, 11.7852)
Luminance0.0371 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#313161 #616131
analogous
#314961 #313161 #493161
triadic
#313161 #613131 #316131
tetradic
#313161 #613149 #616131 #316149
square
#313161 #613149 #616131 #316149
split-complementary
#313161 #614931 #496131
monochromatic
#0A0A14 #1C1C38 #313161 #46468A #5E5EAE

Accessibility & contrast

On white

12.05
#313161 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.74
#313161 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #313161
12.05:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##313161#FFFFFF#000000##FFFFFF
##3131611.0012.051.7412.05
#FFFFFF12.051.0021.001.00
#0000001.7421.001.0021.00
##FFFFFF12.051.0021.001.00

Color blindness preview

Protanopia (red-blind)
#1D3863
Deuteranopia (green-blind)
#1A3460
Tritanopia (blue-blind)
#213B44
Achromatopsia (no color)
#363636

Design tokens & code

CSS
--color: #313161;
/* rgb */ color: rgb(49, 49, 97);
/* oklch */ color: oklch(33.9% 0.083 281.1);
Tailwind
colors: {
  custom: {
    50: '#6c698e',
    500: '#313161',
    950: '#000000',
  },
}
SCSS
$custom: #313161;
$custom-light: #6c698e;
$custom-dark: #000000;
JSON
{
  "hex": "#313161",
  "rgb": {
    "r": 49,
    "g": 49,
    "b": 97
  },
  "hsl": {
    "h": 240,
    "s": 32.877,
    "l": 28.627
  },
  "oklch": {
    "l": 0.33921,
    "c": 0.08264,
    "h": 281.1
  },
  "luminance": 0.03713
}

Semantic roles & 50–950 ramp

primary
#313161
secondary
#92925C
accent
#C95FC9
background
#F6F6F8
surface
#ECEBF0
border
#C7C6CB
text
#07060C
muted
#7A7A7D

Preview Lab

Preview with #313161

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

Preview Lab → · Contrast checker → · Palette generator →

#313161 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva