#512BA1#512BA1

#512BA1 is a dark, vivid violet. Relative luminance 0.060; OKLCH L 41.3% C 0.177 H 291.3°. Best body text is #FFFFFF at 9.50:1 contrast (WCAG AA passes).

Color values

HEX#512BA1
RGBrgb(81, 43, 161)
HSLhsl(259, 58%, 40%)
HSVhsv(259, 73%, 63%)
CMYKcmyk(49.7%, 73.3%, 0%, 36.9%)
CIE-LABlab(29.54, 45.05, -57.59)
CIE-LCHlch(29.54, 73.12, 308.04°)
OKLaboklab(41.26% 0.0646 -0.1653)
OKLCHoklch(41.26% 0.177 291.3)
XYZxyz(10.6884, 6.0499, 34.3159)
Luminance0.0605 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#512BA1 #7BA12B
analogous
#2B40A1 #512BA1 #8C2BA1
triadic
#512BA1 #A1512B #2BA151
tetradic
#512BA1 #A12B40 #7BA12B #2BA18C
square
#512BA1 #A12B40 #7BA12B #2BA18C
split-complementary
#512BA1 #A18C2B #40A12B
monochromatic
#201140 #391E71 #512BA1 #6B3ECB #906ED8

Accessibility & contrast

On white

9.50
#512BA1 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.21
#512BA1 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #512BA1
9.50:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##512BA1#FFFFFF#000000##FFFFFF
##512BA11.009.502.219.50
#FFFFFF9.501.0021.001.00
#0000002.2121.001.0021.00
##FFFFFF9.501.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0047A4
Deuteranopia (green-blind)
#00439F
Tritanopia (blue-blind)
#374A63
Achromatopsia (no color)
#464646

Design tokens & code

CSS
--color: #512ba1;
/* rgb */ color: rgb(81, 43, 161);
/* oklch */ color: oklch(41.3% 0.177 291.3);
Tailwind
colors: {
  custom: {
    50: '#8a68be',
    500: '#512ba1',
    950: '#000000',
  },
}
SCSS
$custom: #512ba1;
$custom-light: #8a68be;
$custom-dark: #000000;
JSON
{
  "hex": "#512ba1",
  "rgb": {
    "r": 81,
    "g": 43,
    "b": 161
  },
  "hsl": {
    "h": 259.322,
    "s": 57.843,
    "l": 40
  },
  "oklch": {
    "l": 0.41258,
    "c": 0.17742,
    "h": 291.3
  },
  "luminance": 0.0605
}

Semantic roles & 50–950 ramp

primary
#512BA1
secondary
#A3BF69
accent
#E147AF
background
#F8F6FB
surface
#F0EBF7
border
#CBC6D0
text
#0D0612
muted
#7D7A81

Preview Lab

Preview with #512BA1

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

Preview Lab → · Contrast checker → · Palette generator →

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