#512173#512173

#512173 is a dark, vivid violet. Relative luminance 0.041; OKLCH L 36.1% C 0.136 H 307.8°. Best body text is #FFFFFF at 11.57:1 contrast (WCAG AA passes).

Color values

HEX#512173
RGBrgb(81, 33, 115)
HSLhsl(275, 55%, 29%)
HSVhsv(275, 71%, 45%)
CMYKcmyk(29.6%, 71.3%, 0%, 54.9%)
CIE-LABlab(23.92, 37.83, -38.09)
CIE-LCHlch(23.92, 53.69, 314.81°)
OKLaboklab(36.08% 0.0836 -0.1079)
OKLCHoklch(36.08% 0.136 307.8)
XYZxyz(7.0311, 4.0749, 16.6325)
Luminance0.0408 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#512173 #437321
analogous
#282173 #512173 #73216C
triadic
#512173 #735121 #217351
tetradic
#512173 #732821 #437321 #216C73
square
#512173 #732821 #437321 #216C73
split-complementary
#512173 #6C7321 #217328
monochromatic
#110718 #301343 #512173 #722FA3 #9345CA

Accessibility & contrast

On white

11.57
#512173 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.82
#512173 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #512173
11.57:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##512173#FFFFFF#000000##FFFFFF
##5121731.0011.571.8211.57
#FFFFFF11.571.0021.001.00
#0000001.8221.001.0021.00
##FFFFFF11.571.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003775
Deuteranopia (green-blind)
#0E3971
Tritanopia (blue-blind)
#4C3347
Achromatopsia (no color)
#393939

Design tokens & code

CSS
--color: #512173;
/* rgb */ color: rgb(81, 33, 115);
/* oklch */ color: oklch(36.1% 0.136 307.8);
Tailwind
colors: {
  custom: {
    50: '#85609c',
    500: '#512173',
    950: '#000000',
  },
}
SCSS
$custom: #512173;
$custom-light: #85609c;
$custom-dark: #000000;
JSON
{
  "hex": "#512173",
  "rgb": {
    "r": 81,
    "g": 33,
    "b": 115
  },
  "hsl": {
    "h": 275.122,
    "s": 55.405,
    "l": 29.02
  },
  "oklch": {
    "l": 0.36076,
    "c": 0.13647,
    "h": 307.8
  },
  "luminance": 0.04075
}

Semantic roles & 50–950 ramp

primary
#512173
secondary
#70A649
accent
#DF4987
background
#F8F5F9
surface
#F0EAF2
border
#CBC6CC
text
#0B050E
muted
#7C797E

Preview Lab

Preview with #512173

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

Preview Lab → · Contrast checker → · Palette generator →

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