#512BA6#512BA6

#512BA6 is a dark, vivid violet. Relative luminance 0.062; OKLCH L 41.7% C 0.183 H 290.2°. Best body text is #FFFFFF at 9.35:1 contrast (WCAG AA passes).

Color values

HEX#512BA6
RGBrgb(81, 43, 166)
HSLhsl(259, 59%, 41%)
HSVhsv(259, 74%, 65%)
CMYKcmyk(51.2%, 74.1%, 0%, 34.9%)
CIE-LABlab(29.98, 46.47, -59.88)
CIE-LCHlch(29.98, 75.80, 307.81°)
OKLaboklab(41.71% 0.0634 -0.172)
OKLCHoklch(41.71% 0.183 290.2)
XYZxyz(11.1382, 6.2298, 36.6846)
Luminance0.0623 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#512BA6 #80A62B
analogous
#2B42A6 #512BA6 #8E2BA6
triadic
#512BA6 #A6512B #2BA651
tetradic
#512BA6 #A62B42 #80A62B #2BA68E
square
#512BA6 #A62B42 #80A62B #2BA68E
split-complementary
#512BA6 #A68E2B #42A62B
monochromatic
#221245 #391E75 #512BA6 #6C41CE #9271DA

Accessibility & contrast

On white

9.35
#512BA6 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.25
#512BA6 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #512BA6
9.35:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##512BA6#FFFFFF#000000##FFFFFF
##512BA61.009.352.259.35
#FFFFFF9.351.0021.001.00
#0000002.2521.001.0021.00
##FFFFFF9.351.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0049AA
Deuteranopia (green-blind)
#0044A4
Tritanopia (blue-blind)
#334C66
Achromatopsia (no color)
#474747

Design tokens & code

CSS
--color: #512ba6;
/* rgb */ color: rgb(81, 43, 166);
/* oklch */ color: oklch(41.7% 0.183 290.2);
Tailwind
colors: {
  custom: {
    50: '#8b68c1',
    500: '#512ba6',
    950: '#000000',
  },
}
SCSS
$custom: #512ba6;
$custom-light: #8b68c1;
$custom-dark: #000000;
JSON
{
  "hex": "#512ba6",
  "rgb": {
    "r": 81,
    "g": 43,
    "b": 166
  },
  "hsl": {
    "h": 258.537,
    "s": 58.852,
    "l": 40.98
  },
  "oklch": {
    "l": 0.41711,
    "c": 0.18329,
    "h": 290.2
  },
  "luminance": 0.0623
}

Semantic roles & 50–950 ramp

primary
#512BA6
secondary
#A7C16B
accent
#E246B2
background
#F9F6FC
surface
#F1EBF8
border
#CBC6D1
text
#0D0612
muted
#7E7A81

Preview Lab

Preview with #512BA6

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

Preview Lab → · Contrast checker → · Palette generator →

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