#51128C#51128C

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

Color values

HEX#51128C
RGBrgb(81, 18, 140)
HSLhsl(271, 77%, 31%)
HSVhsv(271, 87%, 55%)
CMYKcmyk(42.1%, 87.1%, 0%, 45.1%)
CIE-LABlab(23.92, 50.14, -53.89)
CIE-LCHlch(23.92, 73.61, 312.93°)
OKLaboklab(36.74% 0.0905 -0.1542)
OKLCHoklch(36.74% 0.179 300.4)
XYZxyz(8.3421, 4.0753, 25.1530)
Luminance0.0408 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#51128C #4D8C12
analogous
#14128C #51128C #8C128A
triadic
#51128C #8C5112 #128C51
tetradic
#51128C #8C1412 #4D8C12 #128A8C
square
#51128C #8C1412 #4D8C12 #128A8C
split-complementary
#51128C #8A8C12 #128C14
monochromatic
#120420 #320B56 #51128C #7019C2 #8F34E5

Accessibility & contrast

On white

11.57
#51128C on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.82
#51128C on #000000
AA ✗AA large ✗AAA ✗

Best text color

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

Contrast matrix

fg \ bg##51128C#FFFFFF#000000##FFFFFF
##51128C1.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)
#00388F
Deuteranopia (green-blind)
#00388A
Tritanopia (blue-blind)
#433752
Achromatopsia (no color)
#393939

Design tokens & code

CSS
--color: #51128c;
/* rgb */ color: rgb(81, 18, 140);
/* oklch */ color: oklch(36.7% 0.179 300.4);
Tailwind
colors: {
  custom: {
    50: '#895baf',
    500: '#51128c',
    950: '#000000',
  },
}
SCSS
$custom: #51128c;
$custom-light: #895baf;
$custom-dark: #000000;
JSON
{
  "hex": "#51128c",
  "rgb": {
    "r": 81,
    "g": 18,
    "b": 140
  },
  "hsl": {
    "h": 270.984,
    "s": 77.215,
    "l": 30.98
  },
  "oklch": {
    "l": 0.36742,
    "c": 0.17879,
    "h": 300.4
  },
  "luminance": 0.04075
}

Semantic roles & 50–950 ramp

primary
#51128C
secondary
#7BC039
accent
#F43491
background
#F8F5FA
surface
#F0E9F5
border
#CBC5CF
text
#0C0410
muted
#7D797F

Preview Lab

Preview with #51128C

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

Preview Lab → · Contrast checker → · Palette generator →

#51128C Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva