#511B7D#511B7D

#511B7D is a dark, vivid violet. Relative luminance 0.040; OKLCH L 36.2% C 0.155 H 304.6°. Best body text is #FFFFFF at 11.65:1 contrast (WCAG AA passes).

Color values

HEX#511B7D
RGBrgb(81, 27, 125)
HSLhsl(273, 64%, 30%)
HSVhsv(273, 78%, 49%)
CMYKcmyk(35.2%, 78.4%, 0%, 51%)
CIE-LABlab(23.72, 43.13, -44.79)
CIE-LCHlch(23.72, 62.18, 313.92°)
OKLaboklab(36.18% 0.0882 -0.1276)
OKLCHoklch(36.18% 0.155 304.6)
XYZxyz(7.4861, 4.0139, 19.7784)
Luminance0.0401 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#511B7D #477D1B
analogous
#201B7D #511B7D #7D1B78
triadic
#511B7D #7D511B #1B7D51
tetradic
#511B7D #7D201B #477D1B #1B787D
square
#511B7D #7D201B #477D1B #1B787D
split-complementary
#511B7D #787D1B #1B7D20
monochromatic
#100519 #30104B #511B7D #7226AF #913DD5

Accessibility & contrast

On white

11.65
#511B7D on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.80
#511B7D on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #511B7D
11.65:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##511B7D#FFFFFF#000000##FFFFFF
##511B7D1.0011.651.8011.65
#FFFFFF11.651.0021.001.00
#0000001.8021.001.0021.00
##FFFFFF11.651.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003780
Deuteranopia (green-blind)
#00387B
Tritanopia (blue-blind)
#49344B
Achromatopsia (no color)
#383838

Design tokens & code

CSS
--color: #511b7d;
/* rgb */ color: rgb(81, 27, 125);
/* oklch */ color: oklch(36.2% 0.155 304.6);
Tailwind
colors: {
  custom: {
    50: '#875ea3',
    500: '#511b7d',
    950: '#000000',
  },
}
SCSS
$custom: #511b7d;
$custom-light: #875ea3;
$custom-dark: #000000;
JSON
{
  "hex": "#511b7d",
  "rgb": {
    "r": 81,
    "g": 27,
    "b": 125
  },
  "hsl": {
    "h": 273.061,
    "s": 64.474,
    "l": 29.804
  },
  "oklch": {
    "l": 0.36184,
    "c": 0.15506,
    "h": 304.6
  },
  "luminance": 0.04014
}

Semantic roles & 50–950 ramp

primary
#511B7D
secondary
#74B143
accent
#E7408B
background
#F8F5FA
surface
#F0E9F4
border
#CBC5CE
text
#0C050F
muted
#7D797F

Preview Lab

Preview with #511B7D

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

Preview Lab → · Contrast checker → · Palette generator →

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