#512CB1#512CB1

#512CB1 is a dark, vivid violet. Relative luminance 0.067; OKLCH L 42.9% C 0.195 H 287.9°. Best body text is #FFFFFF at 8.96:1 contrast (WCAG AA passes).

Color values

HEX#512CB1
RGBrgb(81, 44, 177)
HSLhsl(257, 60%, 43%)
HSVhsv(257, 75%, 69%)
CMYKcmyk(54.2%, 75.1%, 0%, 30.6%)
CIE-LABlab(31.17, 49.08, -64.54)
CIE-LCHlch(31.17, 81.08, 307.26°)
OKLaboklab(42.86% 0.0599 -0.1856)
OKLCHoklch(42.86% 0.195 287.9)
XYZxyz(12.2275, 6.7244, 42.2401)
Luminance0.0673 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#512CB1 #8CB12C
analogous
#2C49B1 #512CB1 #932CB1
triadic
#512CB1 #B1512C #2CB151
tetradic
#512CB1 #B12C49 #8CB12C #2CB193
square
#512CB1 #B12C49 #8CB12C #2CB193
split-complementary
#512CB1 #B1932C #49B12C
monochromatic
#24144F #3B2080 #512CB1 #6F49D2 #957ADE

Accessibility & contrast

On white

8.96
#512CB1 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

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

Best text color

#FFFFFF on #512CB1
8.96:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##512CB1#FFFFFF#000000##FFFFFF
##512CB11.008.962.358.96
#FFFFFF8.961.0021.001.00
#0000002.3521.001.0021.00
##FFFFFF8.961.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004CB5
Deuteranopia (green-blind)
#0046AF
Tritanopia (blue-blind)
#2A516C
Achromatopsia (no color)
#494949

Design tokens & code

CSS
--color: #512cb1;
/* rgb */ color: rgb(81, 44, 177);
/* oklch */ color: oklch(42.9% 0.195 287.9);
Tailwind
colors: {
  custom: {
    50: '#8c69c9',
    500: '#512cb1',
    950: '#000000',
  },
}
SCSS
$custom: #512cb1;
$custom-light: #8c69c9;
$custom-dark: #000000;
JSON
{
  "hex": "#512cb1",
  "rgb": {
    "r": 81,
    "g": 44,
    "b": 177
  },
  "hsl": {
    "h": 256.692,
    "s": 60.181,
    "l": 43.333
  },
  "oklch": {
    "l": 0.42856,
    "c": 0.19503,
    "h": 287.9
  },
  "luminance": 0.06725
}

Semantic roles & 50–950 ramp

primary
#512CB1
secondary
#AFC673
accent
#E344B7
background
#F9F6FC
surface
#F1EBF8
border
#CBC6D1
text
#0D0713
muted
#7E7A82

Preview Lab

Preview with #512CB1

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

Preview Lab → · Contrast checker → · Palette generator →

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