#512F96#512F96

#512F96 is a dark, vivid violet. Relative luminance 0.060; OKLCH L 40.8% C 0.159 H 293.2°. Best body text is #FFFFFF at 9.56:1 contrast (WCAG AA passes).

Color values

HEX#512F96
RGBrgb(81, 47, 150)
HSLhsl(260, 52%, 39%)
HSVhsv(260, 69%, 59%)
CMYKcmyk(46%, 68.7%, 0%, 41.2%)
CIE-LABlab(29.37, 39.79, -51.16)
CIE-LCHlch(29.37, 64.81, 307.87°)
OKLaboklab(40.85% 0.0627 -0.1464)
OKLCHoklch(40.85% 0.159 293.2)
XYZxyz(9.9134, 5.9841, 29.4810)
Luminance0.0598 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#512F96 #74962F
analogous
#2F4096 #512F96 #842F96
triadic
#512F96 #96512F #2F9651
tetradic
#512F96 #962F40 #74962F #2F9684
square
#512F96 #962F40 #74962F #2F9684
split-complementary
#512F96 #96842F #40962F
monochromatic
#1F1239 #382067 #512F96 #6B3FC3 #8F6ED2

Accessibility & contrast

On white

9.56
#512F96 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.20
#512F96 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #512F96
9.56:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##512F96#FFFFFF#000000##FFFFFF
##512F961.009.562.209.56
#FFFFFF9.561.0021.001.00
#0000002.2021.001.0021.00
##FFFFFF9.561.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004699
Deuteranopia (green-blind)
#004394
Tritanopia (blue-blind)
#3D485E
Achromatopsia (no color)
#454545

Design tokens & code

CSS
--color: #512f96;
/* rgb */ color: rgb(81, 47, 150);
/* oklch */ color: oklch(40.8% 0.159 293.2);
Tailwind
colors: {
  custom: {
    50: '#886ab6',
    500: '#512f96',
    950: '#000000',
  },
}
SCSS
$custom: #512f96;
$custom-light: #886ab6;
$custom-dark: #000000;
JSON
{
  "hex": "#512f96",
  "rgb": {
    "r": 81,
    "g": 47,
    "b": 150
  },
  "hsl": {
    "h": 259.806,
    "s": 52.284,
    "l": 38.627
  },
  "oklch": {
    "l": 0.4085,
    "c": 0.15926,
    "h": 293.2
  },
  "luminance": 0.05984
}

Semantic roles & 50–950 ramp

primary
#512F96
secondary
#9EB968
accent
#DC4CAC
background
#F8F6FB
surface
#F0EBF6
border
#CBC6D0
text
#0C0611
muted
#7D7A80

Preview Lab

Preview with #512F96

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

Preview Lab → · Contrast checker → · Palette generator →

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