#512D94#512D94

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

Color values

HEX#512D94
RGBrgb(81, 45, 148)
HSLhsl(261, 53%, 38%)
HSVhsv(261, 70%, 58%)
CMYKcmyk(45.3%, 69.6%, 0%, 42%)
CIE-LABlab(28.81, 40.32, -50.85)
CIE-LCHlch(28.81, 64.89, 308.41°)
OKLaboklab(40.39% 0.0652 -0.1455)
OKLCHoklch(40.39% 0.159 294.1)
XYZxyz(9.6756, 5.7640, 28.6140)
Luminance0.0576 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#512D94 #70942D
analogous
#2D3C94 #512D94 #842D94
triadic
#512D94 #94512D #2D9451
tetradic
#512D94 #942D3C #70942D #2D9484
square
#512D94 #942D3C #70942D #2D9484
split-complementary
#512D94 #94842D #3C942D
monochromatic
#1E1036 #371F65 #512D94 #6B3BC3 #8E6AD2

Accessibility & contrast

On white

9.75
#512D94 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

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

Best text color

#FFFFFF on #512D94
9.75:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##512D94#FFFFFF#000000##FFFFFF
##512D941.009.752.159.75
#FFFFFF9.751.0021.001.00
#0000002.1521.001.0021.00
##FFFFFF9.751.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004597
Deuteranopia (green-blind)
#004292
Tritanopia (blue-blind)
#3E465D
Achromatopsia (no color)
#444444

Design tokens & code

CSS
--color: #512d94;
/* rgb */ color: rgb(81, 45, 148);
/* oklch */ color: oklch(40.4% 0.159 294.1);
Tailwind
colors: {
  custom: {
    50: '#8869b4',
    500: '#512d94',
    950: '#000000',
  },
}
SCSS
$custom: #512d94;
$custom-light: #8869b4;
$custom-dark: #000000;
JSON
{
  "hex": "#512d94",
  "rgb": {
    "r": 81,
    "g": 45,
    "b": 148
  },
  "hsl": {
    "h": 260.971,
    "s": 53.368,
    "l": 37.843
  },
  "oklch": {
    "l": 0.40395,
    "c": 0.1594,
    "h": 294.1
  },
  "luminance": 0.05764
}

Semantic roles & 50–950 ramp

primary
#512D94
secondary
#9BB864
accent
#DD4BAA
background
#F8F6FB
surface
#F0EBF6
border
#CBC6D0
text
#0C0611
muted
#7D7A80

Preview Lab

Preview with #512D94

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

Preview Lab → · Contrast checker → · Palette generator →

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