#512D99#512D99

#512D99 is a dark, vivid violet. Relative luminance 0.059; OKLCH L 40.8% C 0.165 H 292.9°. Best body text is #FFFFFF at 9.61:1 contrast (WCAG AA passes).

Color values

HEX#512D99
RGBrgb(81, 45, 153)
HSLhsl(260, 55%, 39%)
HSVhsv(260, 71%, 60%)
CMYKcmyk(47.1%, 70.6%, 0%, 40%)
CIE-LABlab(29.22, 41.74, -53.24)
CIE-LCHlch(29.22, 67.65, 308.10°)
OKLaboklab(40.82% 0.0643 -0.1525)
OKLCHoklch(40.82% 0.165 292.9)
XYZxyz(10.0799, 5.9257, 30.7435)
Luminance0.0593 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#512D99 #75992D
analogous
#2D3F99 #512D99 #872D99
triadic
#512D99 #99512D #2D9951
tetradic
#512D99 #992D3F #75992D #2D9987
square
#512D99 #992D3F #75992D #2D9987
split-complementary
#512D99 #99872D #3F992D
monochromatic
#1F113A #381F6A #512D99 #6B3DC6 #8F6CD4

Accessibility & contrast

On white

9.61
#512D99 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.19
#512D99 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #512D99
9.61:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##512D99#FFFFFF#000000##FFFFFF
##512D991.009.612.199.61
#FFFFFF9.611.0021.001.00
#0000002.1921.001.0021.00
##FFFFFF9.611.0021.001.00

Color blindness preview

Protanopia (red-blind)
#00469C
Deuteranopia (green-blind)
#004397
Tritanopia (blue-blind)
#3B485F
Achromatopsia (no color)
#454545

Design tokens & code

CSS
--color: #512d99;
/* rgb */ color: rgb(81, 45, 153);
/* oklch */ color: oklch(40.8% 0.165 292.9);
Tailwind
colors: {
  custom: {
    50: '#8969b8',
    500: '#512d99',
    950: '#000000',
  },
}
SCSS
$custom: #512d99;
$custom-light: #8969b8;
$custom-dark: #000000;
JSON
{
  "hex": "#512d99",
  "rgb": {
    "r": 81,
    "g": 45,
    "b": 153
  },
  "hsl": {
    "h": 260,
    "s": 54.545,
    "l": 38.824
  },
  "oklch": {
    "l": 0.40821,
    "c": 0.16548,
    "h": 292.9
  },
  "luminance": 0.05926
}

Semantic roles & 50–950 ramp

primary
#512D99
secondary
#9FBB67
accent
#DE4AAD
background
#F8F6FB
surface
#F0EBF6
border
#CBC6D0
text
#0C0611
muted
#7D7A80

Preview Lab

Preview with #512D99

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

Preview Lab → · Contrast checker → · Palette generator →

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