#512B91#512B91

#512B91 is a dark, vivid violet. Relative luminance 0.055; OKLCH L 39.9% C 0.158 H 295.3°. Best body text is #FFFFFF at 9.98:1 contrast (WCAG AA passes).

Color values

HEX#512B91
RGBrgb(81, 43, 145)
HSLhsl(262, 54%, 37%)
HSVhsv(262, 70%, 57%)
CMYKcmyk(44.1%, 70.3%, 0%, 43.1%)
CIE-LABlab(28.17, 40.56, -50.04)
CIE-LCHlch(28.17, 64.41, 309.02°)
OKLaboklab(39.86% 0.0678 -0.1431)
OKLCHoklch(39.86% 0.158 295.3)
XYZxyz(9.3667, 5.5212, 27.3548)
Luminance0.0552 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#512B91 #6B912B
analogous
#2B3891 #512B91 #842B91
triadic
#512B91 #91512B #2B9151
tetradic
#512B91 #912B38 #6B912B #2B9184
square
#512B91 #912B38 #6B912B #2B9184
split-complementary
#512B91 #91842B #38912B
monochromatic
#1C0F33 #371D62 #512B91 #6B39C0 #8D65D1

Accessibility & contrast

On white

9.98
#512B91 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.10
#512B91 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #512B91
9.98:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##512B91#FFFFFF#000000##FFFFFF
##512B911.009.982.109.98
#FFFFFF9.981.0021.001.00
#0000002.1021.001.0021.00
##FFFFFF9.981.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004394
Deuteranopia (green-blind)
#00418F
Tritanopia (blue-blind)
#40445A
Achromatopsia (no color)
#424242

Design tokens & code

CSS
--color: #512b91;
/* rgb */ color: rgb(81, 43, 145);
/* oklch */ color: oklch(39.9% 0.158 295.3);
Tailwind
colors: {
  custom: {
    50: '#8867b2',
    500: '#512b91',
    950: '#000000',
  },
}
SCSS
$custom: #512b91;
$custom-light: #8867b2;
$custom-dark: #000000;
JSON
{
  "hex": "#512b91",
  "rgb": {
    "r": 81,
    "g": 43,
    "b": 145
  },
  "hsl": {
    "h": 262.353,
    "s": 54.255,
    "l": 36.863
  },
  "oklch": {
    "l": 0.39862,
    "c": 0.15833,
    "h": 295.3
  },
  "luminance": 0.05521
}

Semantic roles & 50–950 ramp

primary
#512B91
secondary
#97B860
accent
#DE4AA7
background
#F8F6FB
surface
#F0EBF6
border
#CBC6D0
text
#0C0611
muted
#7D7A80

Preview Lab

Preview with #512B91

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

Preview Lab → · Contrast checker → · Palette generator →

#512B91 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva