#512BB4#512BB4

#512BB4 is a dark, vivid violet. Relative luminance 0.068; OKLCH L 43.0% C 0.199 H 287.4°. Best body text is #FFFFFF at 8.92:1 contrast (WCAG AA passes).

Color values

HEX#512BB4
RGBrgb(81, 43, 180)
HSLhsl(257, 61%, 44%)
HSVhsv(257, 76%, 71%)
CMYKcmyk(55%, 76.1%, 0%, 29.4%)
CIE-LABlab(31.28, 50.42, -66.14)
CIE-LCHlch(31.28, 83.17, 307.32°)
OKLaboklab(43.02% 0.0598 -0.1903)
OKLCHoklch(43.02% 0.199 287.4)
XYZxyz(12.4930, 6.7717, 43.8200)
Luminance0.0677 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#512BB4 #8EB42B
analogous
#2B49B4 #512BB4 #952BB4
triadic
#512BB4 #B4512B #2BB451
tetradic
#512BB4 #B42B49 #8EB42B #2BB495
square
#512BB4 #B42B49 #8EB42B #2BB495
split-complementary
#512BB4 #B4952B #49B42B
monochromatic
#251351 #3B1F83 #512BB4 #6F49D3 #967ADF

Accessibility & contrast

On white

8.92
#512BB4 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.35
#512BB4 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #512BB4
8.92:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##512BB4#FFFFFF#000000##FFFFFF
##512BB41.008.922.358.92
#FFFFFF8.921.0021.001.00
#0000002.3521.001.0021.00
##FFFFFF8.921.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004DB8
Deuteranopia (green-blind)
#0046B1
Tritanopia (blue-blind)
#27526E
Achromatopsia (no color)
#4A4A4A

Design tokens & code

CSS
--color: #512bb4;
/* rgb */ color: rgb(81, 43, 180);
/* oklch */ color: oklch(43.0% 0.199 287.4);
Tailwind
colors: {
  custom: {
    50: '#8d69cc',
    500: '#512bb4',
    950: '#000000',
  },
}
SCSS
$custom: #512bb4;
$custom-light: #8d69cc;
$custom-dark: #000000;
JSON
{
  "hex": "#512bb4",
  "rgb": {
    "r": 81,
    "g": 43,
    "b": 180
  },
  "hsl": {
    "h": 256.642,
    "s": 61.435,
    "l": 43.725
  },
  "oklch": {
    "l": 0.43019,
    "c": 0.19949,
    "h": 287.4
  },
  "luminance": 0.06772
}

Semantic roles & 50–950 ramp

primary
#512BB4
secondary
#B0C773
accent
#E543B8
background
#F9F6FC
surface
#F2EBF9
border
#CCC6D2
text
#0D0613
muted
#7E7A82

Preview Lab

Preview with #512BB4

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

Preview Lab → · Contrast checker → · Palette generator →

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