#511F81#511F81

#511F81 is a dark, vivid violet. Relative luminance 0.043; OKLCH L 37.0% C 0.155 H 302.6°. Best body text is #FFFFFF at 11.27:1 contrast (WCAG AA passes).

Color values

HEX#511F81
RGBrgb(81, 31, 129)
HSLhsl(271, 61%, 31%)
HSVhsv(271, 76%, 51%)
CMYKcmyk(37.2%, 76%, 0%, 49.4%)
CIE-LABlab(24.68, 42.33, -45.74)
CIE-LCHlch(24.68, 62.33, 312.78°)
OKLaboklab(36.97% 0.0833 -0.1304)
OKLCHoklch(36.97% 0.155 302.6)
XYZxyz(7.8448, 4.3143, 21.1841)
Luminance0.0431 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#511F81 #4F811F
analogous
#201F81 #511F81 #811F80
triadic
#511F81 #81511F #1F8151
tetradic
#511F81 #81201F #4F811F #1F8081
square
#511F81 #81201F #4F811F #1F8081
split-complementary
#511F81 #80811F #1F8120
monochromatic
#13071E #321350 #511F81 #702BB2 #8F47D3

Accessibility & contrast

On white

11.27
#511F81 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.86
#511F81 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #511F81
11.27:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##511F81#FFFFFF#000000##FFFFFF
##511F811.0011.271.8611.27
#FFFFFF11.271.0021.001.00
#0000001.8621.001.0021.00
##FFFFFF11.271.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003A84
Deuteranopia (green-blind)
#003A7F
Tritanopia (blue-blind)
#47374E
Achromatopsia (no color)
#3B3B3B

Design tokens & code

CSS
--color: #511f81;
/* rgb */ color: rgb(81, 31, 129);
/* oklch */ color: oklch(37.0% 0.155 302.6);
Tailwind
colors: {
  custom: {
    50: '#8760a6',
    500: '#511f81',
    950: '#000000',
  },
}
SCSS
$custom: #511f81;
$custom-light: #8760a6;
$custom-dark: #000000;
JSON
{
  "hex": "#511f81",
  "rgb": {
    "r": 81,
    "g": 31,
    "b": 129
  },
  "hsl": {
    "h": 270.612,
    "s": 61.25,
    "l": 31.373
  },
  "oklch": {
    "l": 0.3697,
    "c": 0.15474,
    "h": 302.6
  },
  "luminance": 0.04314
}

Semantic roles & 50–950 ramp

primary
#511F81
secondary
#7DB448
accent
#E44392
background
#F8F5FA
surface
#F0EAF4
border
#CBC6CE
text
#0C050F
muted
#7D797F

Preview Lab

Preview with #511F81

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

Preview Lab → · Contrast checker → · Palette generator →

#511F81 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva