#512AAE#512AAE

#512AAE is a dark, vivid violet. Relative luminance 0.065; OKLCH L 42.3% C 0.194 H 288.7°. Best body text is #FFFFFF at 9.16:1 contrast (WCAG AA passes).

Color values

HEX#512AAE
RGBrgb(81, 42, 174)
HSLhsl(258, 61%, 42%)
HSVhsv(258, 76%, 68%)
CMYKcmyk(53.4%, 75.9%, 0%, 31.8%)
CIE-LABlab(30.55, 49.22, -63.77)
CIE-LCHlch(30.55, 80.55, 307.66°)
OKLaboklab(42.33% 0.0622 -0.1834)
OKLCHoklch(42.33% 0.194 288.7)
XYZxyz(11.8590, 6.4607, 40.6584)
Luminance0.0646 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#512AAE #87AE2A
analogous
#2A45AE #512AAE #932AAE
triadic
#512AAE #AE512A #2AAE51
tetradic
#512AAE #AE2A45 #87AE2A #2AAE93
square
#512AAE #AE2A45 #87AE2A #2AAE93
split-complementary
#512AAE #AE932A #45AE2A
monochromatic
#23124B #3A1E7D #512AAE #6D43D2 #9475DE

Accessibility & contrast

On white

9.16
#512AAE on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.29
#512AAE on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #512AAE
9.16:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##512AAE#FFFFFF#000000##FFFFFF
##512AAE1.009.162.299.16
#FFFFFF9.161.0021.001.00
#0000002.2921.001.0021.00
##FFFFFF9.161.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004BB2
Deuteranopia (green-blind)
#0045AC
Tritanopia (blue-blind)
#2D4F6A
Achromatopsia (no color)
#484848

Design tokens & code

CSS
--color: #512aae;
/* rgb */ color: rgb(81, 42, 174);
/* oklch */ color: oklch(42.3% 0.194 288.7);
Tailwind
colors: {
  custom: {
    50: '#8c68c7',
    500: '#512aae',
    950: '#000000',
  },
}
SCSS
$custom: #512aae;
$custom-light: #8c68c7;
$custom-dark: #000000;
JSON
{
  "hex": "#512aae",
  "rgb": {
    "r": 81,
    "g": 42,
    "b": 174
  },
  "hsl": {
    "h": 257.727,
    "s": 61.111,
    "l": 42.353
  },
  "oklch": {
    "l": 0.42331,
    "c": 0.19362,
    "h": 288.7
  },
  "luminance": 0.06461
}

Semantic roles & 50–950 ramp

primary
#512AAE
secondary
#ACC56F
accent
#E444B5
background
#F9F6FC
surface
#F1EBF8
border
#CBC6D1
text
#0D0613
muted
#7E7A82

Preview Lab

Preview with #512AAE

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

Preview Lab → · Contrast checker → · Palette generator →

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