#511796#511796

#511796 is a dark, vivid violet. Relative luminance 0.046; OKLCH L 38.1% C 0.185 H 296.9°. Best body text is #FFFFFF at 10.98:1 contrast (WCAG AA passes).

Color values

HEX#511796
RGBrgb(81, 23, 150)
HSLhsl(267, 73%, 34%)
HSVhsv(267, 85%, 59%)
CMYKcmyk(46%, 84.7%, 0%, 41.2%)
CIE-LABlab(25.45, 50.92, -57.57)
CIE-LCHlch(25.45, 76.85, 311.49°)
OKLaboklab(38.09% 0.0836 -0.165)
OKLCHoklch(38.09% 0.185 296.9)
XYZxyz(9.2033, 4.5639, 29.2443)
Luminance0.0456 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#511796 #5C9617
analogous
#171C96 #511796 #911796
triadic
#511796 #965117 #179651
tetradic
#511796 #96171C #5C9617 #179691
square
#511796 #96171C #5C9617 #179691
split-complementary
#511796 #969117 #1C9617
monochromatic
#18072C #340F61 #511796 #6E1FCB #8D45E2

Accessibility & contrast

On white

10.98
#511796 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.91
#511796 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #511796
10.98:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##511796#FFFFFF#000000##FFFFFF
##5117961.0010.981.9110.98
#FFFFFF10.981.0021.001.00
#0000001.9121.001.0021.00
##FFFFFF10.981.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003D99
Deuteranopia (green-blind)
#003B94
Tritanopia (blue-blind)
#3E3D59
Achromatopsia (no color)
#3C3C3C

Design tokens & code

CSS
--color: #511796;
/* rgb */ color: rgb(81, 23, 150);
/* oklch */ color: oklch(38.1% 0.185 296.9);
Tailwind
colors: {
  custom: {
    50: '#8a5db6',
    500: '#511796',
    950: '#000000',
  },
}
SCSS
$custom: #511796;
$custom-light: #8a5db6;
$custom-dark: #000000;
JSON
{
  "hex": "#511796",
  "rgb": {
    "r": 81,
    "g": 23,
    "b": 150
  },
  "hsl": {
    "h": 267.402,
    "s": 73.41,
    "l": 33.922
  },
  "oklch": {
    "l": 0.38093,
    "c": 0.18499,
    "h": 296.9
  },
  "luminance": 0.04564
}

Semantic roles & 50–950 ramp

primary
#511796
secondary
#8AC345
accent
#F0389C
background
#F8F5FB
surface
#F0E9F6
border
#CBC5D0
text
#0D0511
muted
#7D7980

Preview Lab

Preview with #511796

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

Preview Lab → · Contrast checker → · Palette generator →

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