#51287B#51287B

#51287B is a dark, vivid violet. Relative luminance 0.047; OKLCH L 37.7% C 0.136 H 303.1°. Best body text is #FFFFFF at 10.83:1 contrast (WCAG AA passes).

Color values

HEX#51287B
RGBrgb(81, 40, 123)
HSLhsl(270, 51%, 32%)
HSVhsv(270, 67%, 48%)
CMYKcmyk(34.1%, 67.5%, 0%, 51.8%)
CIE-LABlab(25.85, 36.19, -40.06)
CIE-LCHlch(25.85, 53.99, 312.10°)
OKLaboklab(37.66% 0.0742 -0.1137)
OKLCHoklch(37.66% 0.136 303.1)
XYZxyz(7.7265, 4.6970, 19.2346)
Luminance0.0470 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#51287B #527B28
analogous
#28287B #51287B #7B287B
triadic
#51287B #7B5128 #287B51
tetradic
#51287B #7B2828 #527B28 #287B7B
square
#51287B #7B2828 #527B28 #287B7B
split-complementary
#51287B #7B7B28 #287B28
monochromatic
#140A1F #33194D #51287B #6F37A9 #8E56C8

Accessibility & contrast

On white

10.83
#51287B on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.94
#51287B on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #51287B
10.83:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##51287B#FFFFFF#000000##FFFFFF
##51287B1.0010.831.9410.83
#FFFFFF10.831.0021.001.00
#0000001.9421.001.0021.00
##FFFFFF10.831.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003C7E
Deuteranopia (green-blind)
#0B3D79
Tritanopia (blue-blind)
#493A4E
Achromatopsia (no color)
#3D3D3D

Design tokens & code

CSS
--color: #51287b;
/* rgb */ color: rgb(81, 40, 123);
/* oklch */ color: oklch(37.7% 0.136 303.1);
Tailwind
colors: {
  custom: {
    50: '#8565a2',
    500: '#51287b',
    950: '#000000',
  },
}
SCSS
$custom: #51287b;
$custom-light: #8565a2;
$custom-dark: #000000;
JSON
{
  "hex": "#51287b",
  "rgb": {
    "r": 81,
    "g": 40,
    "b": 123
  },
  "hsl": {
    "h": 269.639,
    "s": 50.92,
    "l": 31.961
  },
  "oklch": {
    "l": 0.37656,
    "c": 0.13579,
    "h": 303.1
  },
  "luminance": 0.04697
}

Semantic roles & 50–950 ramp

primary
#51287B
secondary
#80AD52
accent
#DA4D95
background
#F8F6FA
surface
#F0EBF3
border
#CBC6CD
text
#0B060F
muted
#7C7A7F

Preview Lab

Preview with #51287B

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

Preview Lab → · Contrast checker → · Palette generator →

#51287B Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva