#311D56#311D56

#311D56 is a dark, moderate violet. Relative luminance 0.022; OKLCH L 29.1% C 0.099 H 295.8°. Best body text is #FFFFFF at 14.58:1 contrast (WCAG AA passes).

Color values

HEX#311D56
RGBrgb(49, 29, 86)
HSLhsl(261, 50%, 23%)
HSVhsv(261, 66%, 34%)
CMYKcmyk(43%, 66.3%, 0%, 66.3%)
CIE-LABlab(16.52, 24.33, -31.21)
CIE-LCHlch(16.52, 39.57, 307.94°)
OKLaboklab(29.07% 0.043 -0.0889)
OKLCHoklch(29.07% 0.099 295.8)
XYZxyz(3.3853, 2.2035, 9.0493)
Luminance0.0220 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#311D56 #42561D
analogous
#1D2556 #311D56 #4E1D56
triadic
#311D56 #56311D #1D5631
tetradic
#311D56 #561D25 #42561D #1D564E
square
#311D56 #561D25 #42561D #1D564E
split-complementary
#311D56 #564E1D #25561D
monochromatic
#0D0817 #170E28 #311D56 #4B2C84 #653CB2

Accessibility & contrast

On white

14.58
#311D56 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.44
#311D56 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #311D56
14.58:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##311D56#FFFFFF#000000##FFFFFF
##311D561.0014.581.4414.58
#FFFFFF14.581.0021.001.00
#0000001.4421.001.0021.00
##FFFFFF14.581.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002958
Deuteranopia (green-blind)
#022855
Tritanopia (blue-blind)
#282A36
Achromatopsia (no color)
#292929

Design tokens & code

CSS
--color: #311d56;
/* rgb */ color: rgb(49, 29, 86);
/* oklch */ color: oklch(29.1% 0.099 295.8);
Tailwind
colors: {
  custom: {
    50: '#6c5a86',
    500: '#311d56',
    950: '#000000',
  },
}
SCSS
$custom: #311d56;
$custom-light: #6c5a86;
$custom-dark: #000000;
JSON
{
  "hex": "#311d56",
  "rgb": {
    "r": 49,
    "g": 29,
    "b": 86
  },
  "hsl": {
    "h": 261.053,
    "s": 49.565,
    "l": 22.549
  },
  "oklch": {
    "l": 0.29074,
    "c": 0.09871,
    "h": 295.8
  },
  "luminance": 0.02204
}

Semantic roles & 50–950 ramp

primary
#311D56
secondary
#728B44
accent
#D94FA9
background
#F6F5F8
surface
#ECE9EF
border
#C7C5CA
text
#07040B
muted
#7A797C

Preview Lab

Preview with #311D56

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

Preview Lab → · Contrast checker → · Palette generator →

#311D56 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva