#512C96#512C96

#512C96 is a dark, vivid violet. Relative luminance 0.058; OKLCH L 40.4% C 0.163 H 293.8°. Best body text is #FFFFFF at 9.76:1 contrast (WCAG AA passes).

Color values

HEX#512C96
RGBrgb(81, 44, 150)
HSLhsl(261, 55%, 38%)
HSVhsv(261, 71%, 59%)
CMYKcmyk(46%, 70.7%, 0%, 41.2%)
CIE-LABlab(28.78, 41.43, -52.13)
CIE-LCHlch(28.78, 66.58, 308.48°)
OKLaboklab(40.42% 0.0659 -0.1492)
OKLCHoklch(40.42% 0.163 293.8)
XYZxyz(9.7975, 5.7524, 29.4424)
Luminance0.0575 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#512C96 #71962C
analogous
#2C3C96 #512C96 #862C96
triadic
#512C96 #96512C #2C9651
tetradic
#512C96 #962C3C #71962C #2C9686
square
#512C96 #962C3C #71962C #2C9686
split-complementary
#512C96 #96862C #3C962C
monochromatic
#1E1037 #371E67 #512C96 #6B3AC5 #8E69D3

Accessibility & contrast

On white

9.76
#512C96 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.15
#512C96 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #512C96
9.76:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##512C96#FFFFFF#000000##FFFFFF
##512C961.009.762.159.76
#FFFFFF9.761.0021.001.00
#0000002.1521.001.0021.00
##FFFFFF9.761.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004599
Deuteranopia (green-blind)
#004294
Tritanopia (blue-blind)
#3D465D
Achromatopsia (no color)
#444444

Design tokens & code

CSS
--color: #512c96;
/* rgb */ color: rgb(81, 44, 150);
/* oklch */ color: oklch(40.4% 0.163 293.8);
Tailwind
colors: {
  custom: {
    50: '#8868b6',
    500: '#512c96',
    950: '#000000',
  },
}
SCSS
$custom: #512c96;
$custom-light: #8868b6;
$custom-dark: #000000;
JSON
{
  "hex": "#512c96",
  "rgb": {
    "r": 81,
    "g": 44,
    "b": 150
  },
  "hsl": {
    "h": 260.943,
    "s": 54.639,
    "l": 38.039
  },
  "oklch": {
    "l": 0.40425,
    "c": 0.16309,
    "h": 293.8
  },
  "luminance": 0.05753
}

Semantic roles & 50–950 ramp

primary
#512C96
secondary
#9CBA64
accent
#DE4AAA
background
#F8F6FB
surface
#F0EBF6
border
#CBC6D0
text
#0C0611
muted
#7D7A80

Preview Lab

Preview with #512C96

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

Preview Lab → · Contrast checker → · Palette generator →

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