#512EC4#512EC4

#512EC4 is a dark, highly saturated violet. Relative luminance 0.077; OKLCH L 44.9% C 0.215 H 284.4°. Best body text is #FFFFFF at 8.27:1 contrast (WCAG AA passes).

Color values

HEX#512EC4
RGBrgb(81, 46, 196)
HSLhsl(254, 62%, 47%)
HSVhsv(254, 77%, 77%)
CMYKcmyk(58.7%, 76.5%, 0%, 23.1%)
CIE-LABlab(33.32, 53.52, -72.23)
CIE-LCHlch(33.32, 89.90, 306.54°)
OKLaboklab(44.91% 0.0534 -0.2081)
OKLCHoklch(44.91% 0.215 284.4)
XYZxyz(14.3311, 7.6879, 52.9426)
Luminance0.0769 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#512EC4 #A1C42E
analogous
#2E56C4 #512EC4 #9C2EC4
triadic
#512EC4 #C4512E #2EC451
tetradic
#512EC4 #C42E56 #A1C42E #2EC49C
square
#512EC4 #C42E56 #A1C42E #2EC49C
split-complementary
#512EC4 #C49C2E #56C42E
monochromatic
#281761 #3D2292 #512EC4 #7558D8 #9E89E3

Accessibility & contrast

On white

8.27
#512EC4 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.54
#512EC4 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #512EC4
8.27:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##512EC4#FFFFFF#000000##FFFFFF
##512EC41.008.272.548.27
#FFFFFF8.271.0021.001.00
#0000002.5421.001.0021.00
##FFFFFF8.271.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0053C8
Deuteranopia (green-blind)
#004AC1
Tritanopia (blue-blind)
#085978
Achromatopsia (no color)
#4E4E4E

Design tokens & code

CSS
--color: #512ec4;
/* rgb */ color: rgb(81, 46, 196);
/* oklch */ color: oklch(44.9% 0.215 284.4);
Tailwind
colors: {
  custom: {
    50: '#8f6bd7',
    500: '#512ec4',
    950: '#000000',
  },
}
SCSS
$custom: #512ec4;
$custom-light: #8f6bd7;
$custom-dark: #000000;
JSON
{
  "hex": "#512ec4",
  "rgb": {
    "r": 81,
    "g": 46,
    "b": 196
  },
  "hsl": {
    "h": 254,
    "s": 61.983,
    "l": 47.451
  },
  "oklch": {
    "l": 0.44914,
    "c": 0.21486,
    "h": 284.4
  },
  "luminance": 0.07689
}

Semantic roles & 50–950 ramp

primary
#512EC4
secondary
#BBCD81
accent
#E543BF
background
#F9F6FD
surface
#F2EBFA
border
#CCC6D3
text
#0E0715
muted
#7E7A83

Preview Lab

Preview with #512EC4

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

Preview Lab → · Contrast checker → · Palette generator →

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