#51188B#51188B

#51188B is a dark, vivid violet. Relative luminance 0.043; OKLCH L 37.1% C 0.173 H 300.1°. Best body text is #FFFFFF at 11.33:1 contrast (WCAG AA passes).

Color values

HEX#51188B
RGBrgb(81, 24, 139)
HSLhsl(270, 71%, 32%)
HSVhsv(270, 83%, 55%)
CMYKcmyk(41.7%, 82.7%, 0%, 45.5%)
CIE-LABlab(24.53, 47.81, -52.26)
CIE-LCHlch(24.53, 70.83, 312.46°)
OKLaboklab(37.14% 0.0867 -0.1495)
OKLCHoklch(37.14% 0.173 300.1)
XYZxyz(8.3790, 4.2666, 24.8032)
Luminance0.0427 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#51188B #528B18
analogous
#18198B #51188B #8B188B
triadic
#51188B #8B5118 #188B51
tetradic
#51188B #8B1819 #528B18 #188B8B
square
#51188B #8B1819 #528B18 #188B8B
split-complementary
#51188B #8B8B18 #198B18
monochromatic
#140623 #330F57 #51188B #6F21BF #8E3FDE

Accessibility & contrast

On white

11.33
#51188B on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.85
#51188B on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #51188B
11.33:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##51188B#FFFFFF#000000##FFFFFF
##51188B1.0011.331.8511.33
#FFFFFF11.331.0021.001.00
#0000001.8521.001.0021.00
##FFFFFF11.331.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003A8E
Deuteranopia (green-blind)
#003989
Tritanopia (blue-blind)
#433852
Achromatopsia (no color)
#3A3A3A

Design tokens & code

CSS
--color: #51188b;
/* rgb */ color: rgb(81, 24, 139);
/* oklch */ color: oklch(37.1% 0.173 300.1);
Tailwind
colors: {
  custom: {
    50: '#885dae',
    500: '#51188b',
    950: '#000000',
  },
}
SCSS
$custom: #51188b;
$custom-light: #885dae;
$custom-dark: #000000;
JSON
{
  "hex": "#51188b",
  "rgb": {
    "r": 81,
    "g": 24,
    "b": 139
  },
  "hsl": {
    "h": 269.739,
    "s": 70.552,
    "l": 31.961
  },
  "oklch": {
    "l": 0.37138,
    "c": 0.17281,
    "h": 300.1
  },
  "luminance": 0.04267
}

Semantic roles & 50–950 ramp

primary
#51188B
secondary
#80BE40
accent
#ED3A95
background
#F8F5FA
surface
#F0E9F4
border
#CBC5CE
text
#0C0510
muted
#7D797F

Preview Lab

Preview with #51188B

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

Preview Lab → · Contrast checker → · Palette generator →

#51188B Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva