#51228D#51228D

#51228D is a dark, vivid violet. Relative luminance 0.048; OKLCH L 38.4% C 0.165 H 298.1°. Best body text is #FFFFFF at 10.70:1 contrast (WCAG AA passes).

Color values

HEX#51228D
RGBrgb(81, 34, 141)
HSLhsl(266, 61%, 34%)
HSVhsv(266, 76%, 55%)
CMYKcmyk(42.6%, 75.9%, 0%, 44.7%)
CIE-LABlab(26.20, 44.04, -50.77)
CIE-LCHlch(26.20, 67.21, 310.94°)
OKLaboklab(38.36% 0.0776 -0.1452)
OKLCHoklch(38.36% 0.165 298.1)
XYZxyz(8.7718, 4.8163, 25.6616)
Luminance0.0482 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#51228D #5E8D22
analogous
#22298D #51228D #87228D
triadic
#51228D #8D5122 #228D51
tetradic
#51228D #8D2229 #5E8D22 #228D87
square
#51228D #8D2229 #5E8D22 #228D87
split-complementary
#51228D #8D8722 #298D22
monochromatic
#180A2A #35165C #51228D #6D2EBE #8D54D6

Accessibility & contrast

On white

10.70
#51228D on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.96
#51228D on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #51228D
10.70:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##51228D#FFFFFF#000000##FFFFFF
##51228D1.0010.701.9610.70
#FFFFFF10.701.0021.001.00
#0000001.9621.001.0021.00
##FFFFFF10.701.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003E90
Deuteranopia (green-blind)
#003D8B
Tritanopia (blue-blind)
#423E56
Achromatopsia (no color)
#3E3E3E

Design tokens & code

CSS
--color: #51228d;
/* rgb */ color: rgb(81, 34, 141);
/* oklch */ color: oklch(38.4% 0.165 298.1);
Tailwind
colors: {
  custom: {
    50: '#8862af',
    500: '#51228d',
    950: '#000000',
  },
}
SCSS
$custom: #51228d;
$custom-light: #8862af;
$custom-dark: #000000;
JSON
{
  "hex": "#51228d",
  "rgb": {
    "r": 81,
    "g": 34,
    "b": 141
  },
  "hsl": {
    "h": 266.355,
    "s": 61.143,
    "l": 34.314
  },
  "oklch": {
    "l": 0.38362,
    "c": 0.16462,
    "h": 298.1
  },
  "luminance": 0.04816
}

Semantic roles & 50–950 ramp

primary
#51228D
secondary
#8CB951
accent
#E4449E
background
#F8F6FA
surface
#F0EBF5
border
#CBC6CF
text
#0C0510
muted
#7D7A7F

Preview Lab

Preview with #51228D

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

Preview Lab → · Contrast checker → · Palette generator →

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