#5B227F#5B227F

#5B227F is a dark, vivid violet. Relative luminance 0.049; OKLCH L 38.5% C 0.151 H 309.0°. Best body text is #FFFFFF at 10.60:1 contrast (WCAG AA passes).

Color values

HEX#5B227F
RGBrgb(91, 34, 127)
HSLhsl(277, 58%, 32%)
HSVhsv(277, 73%, 50%)
CMYKcmyk(28.3%, 73.2%, 0%, 50.2%)
CIE-LABlab(26.45, 42.50, -41.55)
CIE-LCHlch(26.45, 59.44, 315.65°)
OKLaboklab(38.48% 0.0952 -0.1177)
OKLCHoklch(38.48% 0.151 309)
XYZxyz(8.7164, 4.9007, 20.5613)
Luminance0.0490 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5B227F #467F22
analogous
#2D227F #5B227F #7F2275
triadic
#5B227F #7F5B22 #227F5B
tetradic
#5B227F #7F2D22 #467F22 #22757F
square
#5B227F #7F2D22 #467F22 #22757F
split-complementary
#5B227F #757F22 #227F2D
monochromatic
#16081E #38154F #5B227F #7E2FAF #9C4CCF

Accessibility & contrast

On white

10.60
#5B227F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.98
#5B227F on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5B227F
10.60:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5B227F#FFFFFF#000000##FFFFFF
##5B227F1.0010.601.9810.60
#FFFFFF10.601.0021.001.00
#0000001.9821.001.0021.00
##FFFFFF10.601.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003C82
Deuteranopia (green-blind)
#0C3F7D
Tritanopia (blue-blind)
#56374E
Achromatopsia (no color)
#3F3F3F

Design tokens & code

CSS
--color: #5b227f;
/* rgb */ color: rgb(91, 34, 127);
/* oklch */ color: oklch(38.5% 0.151 309.0);
Tailwind
colors: {
  custom: {
    50: '#8d62a5',
    500: '#5b227f',
    950: '#000000',
  },
}
SCSS
$custom: #5b227f;
$custom-light: #8d62a5;
$custom-dark: #000000;
JSON
{
  "hex": "#5b227f",
  "rgb": {
    "r": 91,
    "g": 34,
    "b": 127
  },
  "hsl": {
    "h": 276.774,
    "s": 57.764,
    "l": 31.569
  },
  "oklch": {
    "l": 0.38478,
    "c": 0.1514,
    "h": 309
  },
  "luminance": 0.04901
}

Semantic roles & 50–950 ramp

primary
#5B227F
secondary
#73B24B
accent
#E14782
background
#F8F6FA
surface
#F0EBF4
border
#CBC6CE
text
#0D050F
muted
#7D7A7F

Preview Lab

Preview with #5B227F

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

Preview Lab → · Contrast checker → · Palette generator →

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