#511872#511872

#511872 is a dark, vivid violet. Relative luminance 0.036; OKLCH L 34.9% C 0.147 H 309.5°. Best body text is #FFFFFF at 12.18:1 contrast (WCAG AA passes).

Color values

HEX#511872
RGBrgb(81, 24, 114)
HSLhsl(278, 65%, 27%)
HSVhsv(278, 79%, 45%)
CMYKcmyk(28.9%, 78.9%, 0%, 55.3%)
CIE-LABlab(22.36, 41.76, -39.96)
CIE-LCHlch(22.36, 57.80, 316.26°)
OKLaboklab(34.95% 0.0935 -0.1133)
OKLCHoklch(34.95% 0.147 309.5)
XYZxyz(6.7566, 3.6176, 16.2587)
Luminance0.0362 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#511872 #397218
analogous
#241872 #511872 #721866
triadic
#511872 #725118 #187251
tetradic
#511872 #722418 #397218 #186672
square
#511872 #722418 #397218 #186672
split-complementary
#511872 #667218 #187224
monochromatic
#120519 #2D0D3F #511872 #7523A5 #9831D4

Accessibility & contrast

On white

12.18
#511872 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.72
#511872 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #511872
12.18:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##511872#FFFFFF#000000##FFFFFF
##5118721.0012.181.7212.18
#FFFFFF12.181.0021.001.00
#0000001.7221.001.0021.00
##FFFFFF12.181.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003374
Deuteranopia (green-blind)
#003670
Tritanopia (blue-blind)
#4C2E44
Achromatopsia (no color)
#353535

Design tokens & code

CSS
--color: #511872;
/* rgb */ color: rgb(81, 24, 114);
/* oklch */ color: oklch(34.9% 0.147 309.5);
Tailwind
colors: {
  custom: {
    50: '#865c9b',
    500: '#511872',
    950: '#000000',
  },
}
SCSS
$custom: #511872;
$custom-light: #865c9b;
$custom-dark: #000000;
JSON
{
  "hex": "#511872",
  "rgb": {
    "r": 81,
    "g": 24,
    "b": 114
  },
  "hsl": {
    "h": 278,
    "s": 65.217,
    "l": 27.059
  },
  "oklch": {
    "l": 0.34948,
    "c": 0.14695,
    "h": 309.5
  },
  "luminance": 0.03618
}

Semantic roles & 50–950 ramp

primary
#511872
secondary
#65A73E
accent
#E8407D
background
#F8F5F9
surface
#F0E9F2
border
#CBC5CC
text
#0B040E
muted
#7C797E

Preview Lab

Preview with #511872

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

Preview Lab → · Contrast checker → · Palette generator →

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