#512562#512562

#512562 is a dark, moderate purple. Relative luminance 0.040; OKLCH L 35.4% C 0.111 H 315.5°. Best body text is #FFFFFF at 11.73:1 contrast (WCAG AA passes).

Color values

HEX#512562
RGBrgb(81, 37, 98)
HSLhsl(283, 45%, 26%)
HSVhsv(283, 62%, 38%)
CMYKcmyk(17.3%, 62.2%, 0%, 61.6%)
CIE-LABlab(23.52, 31.57, -27.71)
CIE-LCHlch(23.52, 42.01, 318.72°)
OKLaboklab(35.41% 0.079 -0.0775)
OKLCHoklch(35.41% 0.111 315.5)
XYZxyz(6.2592, 3.9545, 11.9865)
Luminance0.0395 (WCAG relative)
Temperaturecool
Familypurple

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#512562 #366225
analogous
#332562 #512562 #622555
triadic
#512562 #625125 #256251
tetradic
#512562 #623325 #366225 #255562
square
#512562 #623325 #366225 #255562
split-complementary
#512562 #556225 #256233
monochromatic
#120816 #2C1436 #512562 #76368E #9A48BA

Accessibility & contrast

On white

11.73
#512562 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.79
#512562 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #512562
11.73:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##512562#FFFFFF#000000##FFFFFF
##5125621.0011.731.7911.73
#FFFFFF11.731.0021.001.00
#0000001.7921.001.0021.00
##FFFFFF11.731.0021.001.00

Color blindness preview

Protanopia (red-blind)
#143564
Deuteranopia (green-blind)
#253960
Tritanopia (blue-blind)
#502F3F
Achromatopsia (no color)
#383838

Design tokens & code

CSS
--color: #512562;
/* rgb */ color: rgb(81, 37, 98);
/* oklch */ color: oklch(35.4% 0.111 315.5);
Tailwind
colors: {
  custom: {
    50: '#84628f',
    500: '#512562',
    950: '#000000',
  },
}
SCSS
$custom: #512562;
$custom-light: #84628f;
$custom-dark: #000000;
JSON
{
  "hex": "#512562",
  "rgb": {
    "r": 81,
    "g": 37,
    "b": 98
  },
  "hsl": {
    "h": 283.279,
    "s": 45.185,
    "l": 26.471
  },
  "oklch": {
    "l": 0.35413,
    "c": 0.11069,
    "h": 315.5
  },
  "luminance": 0.03954
}

Semantic roles & 50–950 ramp

primary
#512562
secondary
#62954E
accent
#D55377
background
#F8F5F8
surface
#EFEAF0
border
#CAC6CB
text
#0B050C
muted
#7C797D

Preview Lab

Preview with #512562

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

Preview Lab → · Contrast checker → · Palette generator →

#512562 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva