#4C157F#4C157F

#4C157F is a dark, vivid violet. Relative luminance 0.036; OKLCH L 35.1% C 0.162 H 301.6°. Best body text is #FFFFFF at 12.20:1 contrast (WCAG AA passes).

Color values

HEX#4C157F
RGBrgb(76, 21, 127)
HSLhsl(271, 72%, 29%)
HSVhsv(271, 83%, 50%)
CMYKcmyk(40.2%, 83.5%, 0%, 50.2%)
CIE-LABlab(22.32, 45.19, -48.37)
CIE-LCHlch(22.32, 66.19, 313.05°)
OKLaboklab(35.11% 0.0851 -0.1382)
OKLCHoklch(35.11% 0.162 301.6)
XYZxyz(7.0785, 3.6051, 20.3975)
Luminance0.0360 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#4C157F #487F15
analogous
#17157F #4C157F #7F157D
triadic
#4C157F #7F4C15 #157F4C
tetradic
#4C157F #7F1715 #487F15 #157D7F
square
#4C157F #7F1715 #487F15 #157D7F
split-complementary
#4C157F #7D7F15 #157F17
monochromatic
#10041A #2D0C4A #4C157F #6B1EB4 #8A31DD

Accessibility & contrast

On white

12.20
#4C157F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.72
#4C157F on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #4C157F
12.20:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##4C157F#FFFFFF#000000##FFFFFF
##4C157F1.0012.201.7212.20
#FFFFFF12.201.0021.001.00
#0000001.7221.001.0021.00
##FFFFFF12.201.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003582
Deuteranopia (green-blind)
#00357D
Tritanopia (blue-blind)
#41334B
Achromatopsia (no color)
#353535

Design tokens & code

CSS
--color: #4c157f;
/* rgb */ color: rgb(76, 21, 127);
/* oklch */ color: oklch(35.1% 0.162 301.6);
Tailwind
colors: {
  custom: {
    50: '#845aa5',
    500: '#4c157f',
    950: '#000000',
  },
}
SCSS
$custom: #4c157f;
$custom-light: #845aa5;
$custom-dark: #000000;
JSON
{
  "hex": "#4c157f",
  "rgb": {
    "r": 76,
    "g": 21,
    "b": 127
  },
  "hsl": {
    "h": 271.132,
    "s": 71.622,
    "l": 29.02
  },
  "oklch": {
    "l": 0.35107,
    "c": 0.16231,
    "h": 301.6
  },
  "luminance": 0.03605
}

Semantic roles & 50–950 ramp

primary
#4C157F
secondary
#76B43C
accent
#EE3990
background
#F8F5FA
surface
#F0E9F4
border
#CBC5CE
text
#0B040F
muted
#7C797F

Preview Lab

Preview with #4C157F

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

Preview Lab → · Contrast checker → · Palette generator →

#4C157F Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva