#51157D#51157D

#51157D is a dark, vivid violet. Relative luminance 0.038; OKLCH L 35.6% C 0.161 H 305.4°. Best body text is #FFFFFF at 11.98:1 contrast (WCAG AA passes).

Color values

HEX#51157D
RGBrgb(81, 21, 125)
HSLhsl(275, 71%, 29%)
HSVhsv(275, 83%, 49%)
CMYKcmyk(35.2%, 83.2%, 0%, 51%)
CIE-LABlab(22.88, 45.54, -46.15)
CIE-LCHlch(22.88, 64.83, 314.62°)
OKLaboklab(35.6% 0.0934 -0.1315)
OKLCHoklch(35.6% 0.161 305.4)
XYZxyz(7.3623, 3.7664, 19.7372)
Luminance0.0377 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#51157D #417D15
analogous
#1D157D #51157D #7D1575
triadic
#51157D #7D5115 #157D51
tetradic
#51157D #7D1D15 #417D15 #15757D
square
#51157D #7D1D15 #417D15 #15757D
split-complementary
#51157D #757D15 #157D1D
monochromatic
#11041A #2F0C49 #51157D #731EB1 #9330DC

Accessibility & contrast

On white

11.98
#51157D on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.75
#51157D on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #51157D
11.98:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##51157D#FFFFFF#000000##FFFFFF
##51157D1.0011.981.7511.98
#FFFFFF11.981.0021.001.00
#0000001.7521.001.0021.00
##FFFFFF11.981.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003580
Deuteranopia (green-blind)
#00377B
Tritanopia (blue-blind)
#49314A
Achromatopsia (no color)
#373737

Design tokens & code

CSS
--color: #51157d;
/* rgb */ color: rgb(81, 21, 125);
/* oklch */ color: oklch(35.6% 0.161 305.4);
Tailwind
colors: {
  custom: {
    50: '#875ba3',
    500: '#51157d',
    950: '#000000',
  },
}
SCSS
$custom: #51157d;
$custom-light: #875ba3;
$custom-dark: #000000;
JSON
{
  "hex": "#51157d",
  "rgb": {
    "r": 81,
    "g": 21,
    "b": 125
  },
  "hsl": {
    "h": 274.615,
    "s": 71.233,
    "l": 28.627
  },
  "oklch": {
    "l": 0.35601,
    "c": 0.16131,
    "h": 305.4
  },
  "luminance": 0.03766
}

Semantic roles & 50–950 ramp

primary
#51157D
secondary
#6EB23C
accent
#EE3A86
background
#F8F5FA
surface
#F0E9F4
border
#CBC5CE
text
#0C040F
muted
#7D797F

Preview Lab

Preview with #51157D

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

Preview Lab → · Contrast checker → · Palette generator →

#51157D Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva