#5B229B#5B229B

#5B229B is a dark, vivid violet. Relative luminance 0.057; OKLCH L 40.8% C 0.181 H 299.5°. Best body text is #FFFFFF at 9.78:1 contrast (WCAG AA passes).

Color values

HEX#5B229B
RGBrgb(91, 34, 155)
HSLhsl(268, 64%, 37%)
HSVhsv(268, 78%, 61%)
CMYKcmyk(41.3%, 78.1%, 0%, 39.2%)
CIE-LABlab(28.73, 49.37, -55.21)
CIE-LCHlch(28.73, 74.07, 311.81°)
OKLaboklab(40.8% 0.0892 -0.1578)
OKLCHoklch(40.8% 0.181 299.5)
XYZxyz(10.8013, 5.7346, 31.5418)
Luminance0.0573 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5B229B #629B22
analogous
#22269B #5B229B #97229B
triadic
#5B229B #9B5B22 #229B5B
tetradic
#5B229B #9B2226 #629B22 #229B97
square
#5B229B #9B2226 #629B22 #229B97
split-complementary
#5B229B #9B9722 #269B22
monochromatic
#200C37 #3E1769 #5B229B #782DCD #985CDB

Accessibility & contrast

On white

9.78
#5B229B on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.15
#5B229B on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5B229B
9.78:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5B229B#FFFFFF#000000##FFFFFF
##5B229B1.009.782.159.78
#FFFFFF9.781.0021.001.00
#0000002.1521.001.0021.00
##FFFFFF9.781.0021.001.00

Color blindness preview

Protanopia (red-blind)
#00449E
Deuteranopia (green-blind)
#004399
Tritanopia (blue-blind)
#4C425E
Achromatopsia (no color)
#444444

Design tokens & code

CSS
--color: #5b229b;
/* rgb */ color: rgb(91, 34, 155);
/* oklch */ color: oklch(40.8% 0.181 299.5);
Tailwind
colors: {
  custom: {
    50: '#9064b9',
    500: '#5b229b',
    950: '#000000',
  },
}
SCSS
$custom: #5b229b;
$custom-light: #9064b9;
$custom-dark: #000000;
JSON
{
  "hex": "#5b229b",
  "rgb": {
    "r": 91,
    "g": 34,
    "b": 155
  },
  "hsl": {
    "h": 268.264,
    "s": 64.021,
    "l": 37.059
  },
  "oklch": {
    "l": 0.40802,
    "c": 0.1813,
    "h": 299.5
  },
  "luminance": 0.05735
}

Semantic roles & 50–950 ramp

primary
#5B229B
secondary
#8FC059
accent
#E74199
background
#F9F6FB
surface
#F2EBF6
border
#CCC6D0
text
#0D0612
muted
#7E7A81

Preview Lab

Preview with #5B229B

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

Preview Lab → · Contrast checker → · Palette generator →

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