#311B72#311B72

#311B72 is a dark, vivid violet. Relative luminance 0.027; OKLCH L 31.3% C 0.139 H 286.9°. Best body text is #FFFFFF at 13.72:1 contrast (WCAG AA passes).

Color values

HEX#311B72
RGBrgb(49, 27, 114)
HSLhsl(255, 62%, 28%)
HSVhsv(255, 76%, 45%)
CMYKcmyk(57%, 76.3%, 0%, 55.3%)
CIE-LABlab(18.59, 34.36, -46.30)
CIE-LCHlch(18.59, 57.65, 306.58°)
OKLaboklab(31.34% 0.0406 -0.1332)
OKLCHoklch(31.34% 0.139 286.9)
XYZxyz(4.6949, 2.6515, 16.1807)
Luminance0.0265 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#311B72 #5C721B
analogous
#1B3172 #311B72 #5C1B72
triadic
#311B72 #72311B #1B7231
tetradic
#311B72 #721B31 #5C721B #1B725C
square
#311B72 #721B31 #5C721B #1B725C
split-complementary
#311B72 #725C1B #31721B
monochromatic
#0B0619 #1C0F41 #311B72 #4627A3 #5E38D0

Accessibility & contrast

On white

13.72
#311B72 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.53
#311B72 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #311B72
13.72:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##311B72#FFFFFF#000000##FFFFFF
##311B721.0013.721.5313.72
#FFFFFF13.721.0021.001.00
#0000001.5321.001.0021.00
##FFFFFF13.721.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002F75
Deuteranopia (green-blind)
#002B70
Tritanopia (blue-blind)
#153345
Achromatopsia (no color)
#2D2D2D

Design tokens & code

CSS
--color: #311b72;
/* rgb */ color: rgb(49, 27, 114);
/* oklch */ color: oklch(31.3% 0.139 286.9);
Tailwind
colors: {
  custom: {
    50: '#715a9b',
    500: '#311b72',
    950: '#000000',
  },
}
SCSS
$custom: #311b72;
$custom-light: #715a9b;
$custom-dark: #000000;
JSON
{
  "hex": "#311b72",
  "rgb": {
    "r": 49,
    "g": 27,
    "b": 114
  },
  "hsl": {
    "h": 255.172,
    "s": 61.702,
    "l": 27.647
  },
  "oklch": {
    "l": 0.31339,
    "c": 0.13921,
    "h": 286.9
  },
  "luminance": 0.02652
}

Semantic roles & 50–950 ramp

primary
#311B72
secondary
#8DA742
accent
#E543BC
background
#F7F5F9
surface
#EDE9F2
border
#C8C5CC
text
#08040E
muted
#7B797E

Preview Lab

Preview with #311B72

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

Preview Lab → · Contrast checker → · Palette generator →

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