#5B307E#5B307E

#5B307E is a dark, vivid violet. Relative luminance 0.058; OKLCH L 40.3% C 0.130 H 306.9°. Best body text is #FFFFFF at 9.68:1 contrast (WCAG AA passes).

Color values

HEX#5B307E
RGBrgb(91, 48, 126)
HSLhsl(273, 45%, 34%)
HSVhsv(273, 62%, 49%)
CMYKcmyk(27.8%, 61.9%, 0%, 50.6%)
CIE-LABlab(29.02, 35.00, -36.79)
CIE-LCHlch(29.02, 50.78, 313.57°)
OKLaboklab(40.31% 0.078 -0.1038)
OKLCHoklch(40.31% 0.13 306.9)
XYZxyz(9.1364, 5.8445, 20.3814)
Luminance0.0584 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5B307E #537E30
analogous
#34307E #5B307E #7E307A
triadic
#5B307E #7E5B30 #307E5B
tetradic
#5B307E #7E3430 #537E30 #307A7E
square
#5B307E #7E3430 #537E30 #307A7E
split-complementary
#5B307E #7A7E30 #307E34
monochromatic
#1B0E25 #3B1F52 #5B307E #7B41AA #9964C4

Accessibility & contrast

On white

9.68
#5B307E on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.17
#5B307E on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5B307E
9.68:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5B307E#FFFFFF#000000##FFFFFF
##5B307E1.009.682.179.68
#FFFFFF9.681.0021.001.00
#0000002.1721.001.0021.00
##FFFFFF9.681.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0E4380
Deuteranopia (green-blind)
#22457C
Tritanopia (blue-blind)
#553F52
Achromatopsia (no color)
#444444

Design tokens & code

CSS
--color: #5b307e;
/* rgb */ color: rgb(91, 48, 126);
/* oklch */ color: oklch(40.3% 0.130 306.9);
Tailwind
colors: {
  custom: {
    50: '#8c6ba4',
    500: '#5b307e',
    950: '#000000',
  },
}
SCSS
$custom: #5b307e;
$custom-light: #8c6ba4;
$custom-dark: #000000;
JSON
{
  "hex": "#5b307e",
  "rgb": {
    "r": 91,
    "g": 48,
    "b": 126
  },
  "hsl": {
    "h": 273.077,
    "s": 44.828,
    "l": 34.118
  },
  "oklch": {
    "l": 0.40305,
    "c": 0.12986,
    "h": 306.9
  },
  "luminance": 0.05844
}

Semantic roles & 50–950 ramp

primary
#5B307E
secondary
#81AB5F
accent
#D5538D
background
#F8F6FA
surface
#F0EBF4
border
#CBC6CE
text
#0C070F
muted
#7D7A7F

Preview Lab

Preview with #5B307E

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

Preview Lab → · Contrast checker → · Palette generator →

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