#512A94#512A94

#512A94 is a dark, vivid violet. Relative luminance 0.055; OKLCH L 40.0% C 0.163 H 294.7°. Best body text is #FFFFFF at 9.96:1 contrast (WCAG AA passes).

Color values

HEX#512A94
RGBrgb(81, 42, 148)
HSLhsl(262, 56%, 37%)
HSVhsv(262, 72%, 58%)
CMYKcmyk(45.3%, 71.6%, 0%, 42%)
CIE-LABlab(28.23, 41.93, -51.79)
CIE-LCHlch(28.23, 66.64, 308.99°)
OKLaboklab(39.98% 0.0683 -0.1482)
OKLCHoklch(39.98% 0.163 294.7)
XYZxyz(9.5652, 5.5431, 28.5772)
Luminance0.0554 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#512A94 #6D942A
analogous
#2A3894 #512A94 #862A94
triadic
#512A94 #94512A #2A9451
tetradic
#512A94 #942A38 #6D942A #2A9486
square
#512A94 #942A38 #6D942A #2A9486
split-complementary
#512A94 #94862A #38942A
monochromatic
#1D0F35 #371C64 #512A94 #6B38C4 #8E65D3

Accessibility & contrast

On white

9.96
#512A94 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.11
#512A94 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #512A94
9.96:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##512A94#FFFFFF#000000##FFFFFF
##512A941.009.962.119.96
#FFFFFF9.961.0021.001.00
#0000002.1121.001.0021.00
##FFFFFF9.961.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004497
Deuteranopia (green-blind)
#004192
Tritanopia (blue-blind)
#3E455C
Achromatopsia (no color)
#434343

Design tokens & code

CSS
--color: #512a94;
/* rgb */ color: rgb(81, 42, 148);
/* oklch */ color: oklch(40.0% 0.163 294.7);
Tailwind
colors: {
  custom: {
    50: '#8867b4',
    500: '#512a94',
    950: '#000000',
  },
}
SCSS
$custom: #512a94;
$custom-light: #8867b4;
$custom-dark: #000000;
JSON
{
  "hex": "#512a94",
  "rgb": {
    "r": 81,
    "g": 42,
    "b": 148
  },
  "hsl": {
    "h": 262.075,
    "s": 55.789,
    "l": 37.255
  },
  "oklch": {
    "l": 0.39981,
    "c": 0.16319,
    "h": 294.7
  },
  "luminance": 0.05543
}

Semantic roles & 50–950 ramp

primary
#512A94
secondary
#99B960
accent
#DF49A8
background
#F8F6FB
surface
#F0EBF6
border
#CBC6D0
text
#0C0611
muted
#7D7A80

Preview Lab

Preview with #512A94

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

Preview Lab → · Contrast checker → · Palette generator →

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