#512AC4#512AC4

#512AC4 is a dark, highly saturated violet. Relative luminance 0.074; OKLCH L 44.5% C 0.218 H 284.8°. Best body text is #FFFFFF at 8.47:1 contrast (WCAG AA passes).

Color values

HEX#512AC4
RGBrgb(81, 42, 196)
HSLhsl(255, 65%, 47%)
HSVhsv(255, 79%, 77%)
CMYKcmyk(58.7%, 78.6%, 0%, 23.1%)
CIE-LABlab(32.68, 55.38, -73.29)
CIE-LCHlch(32.68, 91.86, 307.07°)
OKLaboklab(44.46% 0.0559 -0.2112)
OKLCHoklch(44.46% 0.218 284.8)
XYZxyz(14.1821, 7.3899, 52.8929)
Luminance0.0739 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#512AC4 #9DC42A
analogous
#2A50C4 #512AC4 #9E2AC4
triadic
#512AC4 #C4512A #2AC451
tetradic
#512AC4 #C42A50 #9DC42A #2AC49E
square
#512AC4 #C42A50 #9DC42A #2AC49E
split-complementary
#512AC4 #C49E2A #50C42A
monochromatic
#27145F #3C1F92 #512AC4 #7451DA #9C84E5

Accessibility & contrast

On white

8.47
#512AC4 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.48
#512AC4 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #512AC4
8.47:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##512AC4#FFFFFF#000000##FFFFFF
##512AC41.008.472.488.47
#FFFFFF8.471.0021.001.00
#0000002.4821.001.0021.00
##FFFFFF8.471.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0051C8
Deuteranopia (green-blind)
#0048C1
Tritanopia (blue-blind)
#095877
Achromatopsia (no color)
#4D4D4D

Design tokens & code

CSS
--color: #512ac4;
/* rgb */ color: rgb(81, 42, 196);
/* oklch */ color: oklch(44.5% 0.218 284.8);
Tailwind
colors: {
  custom: {
    50: '#8f69d7',
    500: '#512ac4',
    950: '#000000',
  },
}
SCSS
$custom: #512ac4;
$custom-light: #8f69d7;
$custom-dark: #000000;
JSON
{
  "hex": "#512ac4",
  "rgb": {
    "r": 81,
    "g": 42,
    "b": 196
  },
  "hsl": {
    "h": 255.195,
    "s": 64.706,
    "l": 46.667
  },
  "oklch": {
    "l": 0.44464,
    "c": 0.21848,
    "h": 284.8
  },
  "luminance": 0.07391
}

Semantic roles & 50–950 ramp

primary
#512AC4
secondary
#B9CE7C
accent
#E840BD
background
#F9F6FD
surface
#F2EBFA
border
#CCC6D3
text
#0E0715
muted
#7E7A83

Preview Lab

Preview with #512AC4

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

Preview Lab → · Contrast checker → · Palette generator →

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