#512C91#512C91

#512C91 is a dark, vivid violet. Relative luminance 0.056; OKLCH L 40.0% C 0.157 H 295.1°. Best body text is #FFFFFF at 9.91:1 contrast (WCAG AA passes).

Color values

HEX#512C91
RGBrgb(81, 44, 145)
HSLhsl(262, 53%, 37%)
HSVhsv(262, 70%, 57%)
CMYKcmyk(44.1%, 69.7%, 0%, 43.1%)
CIE-LABlab(28.37, 40.02, -49.72)
CIE-LCHlch(28.37, 63.83, 308.83°)
OKLaboklab(40% 0.0667 -0.1422)
OKLCHoklch(40% 0.157 295.1)
XYZxyz(9.4035, 5.5948, 27.3670)
Luminance0.0559 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#512C91 #6C912C
analogous
#2C3A91 #512C91 #842C91
triadic
#512C91 #91512C #2C9151
tetradic
#512C91 #912C3A #6C912C #2C9184
square
#512C91 #912C3A #6C912C #2C9184
split-complementary
#512C91 #91842C #3A912C
monochromatic
#1D1033 #371E62 #512C91 #6B3AC0 #8E67D1

Accessibility & contrast

On white

9.91
#512C91 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.12
#512C91 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #512C91
9.91:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##512C91#FFFFFF#000000##FFFFFF
##512C911.009.912.129.91
#FFFFFF9.911.0021.001.00
#0000002.1221.001.0021.00
##FFFFFF9.911.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004494
Deuteranopia (green-blind)
#00418F
Tritanopia (blue-blind)
#40455B
Achromatopsia (no color)
#434343

Design tokens & code

CSS
--color: #512c91;
/* rgb */ color: rgb(81, 44, 145);
/* oklch */ color: oklch(40.0% 0.157 295.1);
Tailwind
colors: {
  custom: {
    50: '#8868b2',
    500: '#512c91',
    950: '#000000',
  },
}
SCSS
$custom: #512c91;
$custom-light: #8868b2;
$custom-dark: #000000;
JSON
{
  "hex": "#512c91",
  "rgb": {
    "r": 81,
    "g": 44,
    "b": 145
  },
  "hsl": {
    "h": 261.98,
    "s": 53.439,
    "l": 37.059
  },
  "oklch": {
    "l": 0.40002,
    "c": 0.15703,
    "h": 295.1
  },
  "luminance": 0.05595
}

Semantic roles & 50–950 ramp

primary
#512C91
secondary
#98B762
accent
#DD4BA7
background
#F8F6FB
surface
#F0EBF6
border
#CBC6D0
text
#0C0611
muted
#7D7A80

Preview Lab

Preview with #512C91

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

Preview Lab → · Contrast checker → · Palette generator →

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