#512784#512784

#512784 is a dark, vivid violet. Relative luminance 0.049; OKLCH L 38.2% C 0.148 H 300.1°. Best body text is #FFFFFF at 10.64:1 contrast (WCAG AA passes).

Color values

HEX#512784
RGBrgb(81, 39, 132)
HSLhsl(267, 54%, 34%)
HSVhsv(267, 70%, 52%)
CMYKcmyk(38.6%, 70.5%, 0%, 48.2%)
CIE-LABlab(26.35, 39.13, -44.92)
CIE-LCHlch(26.35, 59.58, 311.06°)
OKLaboklab(38.23% 0.0742 -0.128)
OKLCHoklch(38.23% 0.148 300.1)
XYZxyz(8.2827, 4.8662, 22.3282)
Luminance0.0487 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#512784 #5A8427
analogous
#272B84 #512784 #7F2784
triadic
#512784 #845127 #278451
tetradic
#512784 #84272B #5A8427 #27847F
square
#512784 #84272B #5A8427 #27847F
split-complementary
#512784 #847F27 #2B8427
monochromatic
#170B26 #341955 #512784 #6E35B3 #8D58CE

Accessibility & contrast

On white

10.64
#512784 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.97
#512784 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #512784
10.64:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##512784#FFFFFF#000000##FFFFFF
##5127841.0010.641.9710.64
#FFFFFF10.641.0021.001.00
#0000001.9721.001.0021.00
##FFFFFF10.641.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003E87
Deuteranopia (green-blind)
#003E82
Tritanopia (blue-blind)
#463D52
Achromatopsia (no color)
#3E3E3E

Design tokens & code

CSS
--color: #512784;
/* rgb */ color: rgb(81, 39, 132);
/* oklch */ color: oklch(38.2% 0.148 300.1);
Tailwind
colors: {
  custom: {
    50: '#8664a8',
    500: '#512784',
    950: '#000000',
  },
}
SCSS
$custom: #512784;
$custom-light: #8664a8;
$custom-dark: #000000;
JSON
{
  "hex": "#512784",
  "rgb": {
    "r": 81,
    "g": 39,
    "b": 132
  },
  "hsl": {
    "h": 267.097,
    "s": 54.386,
    "l": 33.529
  },
  "oklch": {
    "l": 0.38231,
    "c": 0.14799,
    "h": 300.1
  },
  "luminance": 0.04866
}

Semantic roles & 50–950 ramp

primary
#512784
secondary
#88B254
accent
#DE4A9B
background
#F8F6FA
surface
#F0EBF4
border
#CBC6CE
text
#0C0610
muted
#7D7A7F

Preview Lab

Preview with #512784

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

Preview Lab → · Contrast checker → · Palette generator →

#512784 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva