#5B127F#5B127F

#5B127F is a dark, vivid purple. Relative luminance 0.042; OKLCH L 37.0% C 0.169 H 310.7°. Best body text is #FFFFFF at 11.43:1 contrast (WCAG AA passes).

Color values

HEX#5B127F
RGBrgb(91, 18, 127)
HSLhsl(280, 75%, 28%)
HSVhsv(280, 86%, 50%)
CMYKcmyk(28.3%, 85.8%, 0%, 50.2%)
CIE-LABlab(24.29, 48.71, -45.06)
CIE-LCHlch(24.29, 66.36, 317.23°)
OKLaboklab(36.96% 0.1099 -0.1279)
OKLCHoklch(36.96% 0.169 310.7)
XYZxyz(8.3607, 4.1893, 20.4427)
Luminance0.0419 (WCAG relative)
Temperaturecool
Familypurple

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5B127F #367F12
analogous
#24127F #5B127F #7F126C
triadic
#5B127F #7F5B12 #127F5B
tetradic
#5B127F #7F2412 #367F12 #126C7F
square
#5B127F #7F2412 #367F12 #126C7F
split-complementary
#5B127F #6C7F12 #127F24
monochromatic
#13041B #350A49 #5B127F #811AB5 #A52BE1

Accessibility & contrast

On white

11.43
#5B127F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.84
#5B127F on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5B127F
11.43:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5B127F#FFFFFF#000000##FFFFFF
##5B127F1.0011.431.8411.43
#FFFFFF11.431.0021.001.00
#0000001.8421.001.0021.00
##FFFFFF11.431.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003782
Deuteranopia (green-blind)
#003B7D
Tritanopia (blue-blind)
#562F4A
Achromatopsia (no color)
#3A3A3A

Design tokens & code

CSS
--color: #5b127f;
/* rgb */ color: rgb(91, 18, 127);
/* oklch */ color: oklch(37.0% 0.169 310.7);
Tailwind
colors: {
  custom: {
    50: '#8e5ba5',
    500: '#5b127f',
    950: '#000000',
  },
}
SCSS
$custom: #5b127f;
$custom-light: #8e5ba5;
$custom-dark: #000000;
JSON
{
  "hex": "#5b127f",
  "rgb": {
    "r": 91,
    "g": 18,
    "b": 127
  },
  "hsl": {
    "h": 280.183,
    "s": 75.172,
    "l": 28.431
  },
  "oklch": {
    "l": 0.36956,
    "c": 0.16863,
    "h": 310.7
  },
  "luminance": 0.04189
}

Semantic roles & 50–950 ramp

primary
#5B127F
secondary
#61B538
accent
#F23674
background
#F9F5FA
surface
#F1E9F4
border
#CBC5CE
text
#0D040F
muted
#7E797F

Preview Lab

Preview with #5B127F

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

Preview Lab → · Contrast checker → · Palette generator →

#5B127F Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva