#4C178C#4C178C

#4C178C is a dark, vivid violet. Relative luminance 0.040; OKLCH L 36.5% C 0.174 H 297.1°. Best body text is #FFFFFF at 11.61:1 contrast (WCAG AA passes).

Color values

HEX#4C178C
RGBrgb(76, 23, 140)
HSLhsl(267, 72%, 32%)
HSVhsv(267, 84%, 55%)
CMYKcmyk(45.7%, 83.6%, 0%, 45.1%)
CIE-LABlab(23.81, 47.70, -54.09)
CIE-LCHlch(23.81, 72.12, 311.40°)
OKLaboklab(36.52% 0.0792 -0.155)
OKLCHoklch(36.52% 0.174 297.1)
XYZxyz(8.0193, 4.0426, 25.1636)
Luminance0.0404 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#4C178C #578C17
analogous
#171D8C #4C178C #86178C
triadic
#4C178C #8C4C17 #178C4C
tetradic
#4C178C #8C171D #578C17 #178C86
square
#4C178C #8C171D #578C17 #178C86
split-complementary
#4C178C #8C8617 #1D8C17
monochromatic
#130623 #2F0E57 #4C178C #6920C1 #873EDF

Accessibility & contrast

On white

11.61
#4C178C on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.81
#4C178C on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #4C178C
11.61:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##4C178C#FFFFFF#000000##FFFFFF
##4C178C1.0011.611.8111.61
#FFFFFF11.611.0021.001.00
#0000001.8121.001.0021.00
##FFFFFF11.611.0021.001.00

Color blindness preview

Protanopia (red-blind)
#00398F
Deuteranopia (green-blind)
#00378A
Tritanopia (blue-blind)
#3B3953
Achromatopsia (no color)
#393939

Design tokens & code

CSS
--color: #4c178c;
/* rgb */ color: rgb(76, 23, 140);
/* oklch */ color: oklch(36.5% 0.174 297.1);
Tailwind
colors: {
  custom: {
    50: '#855caf',
    500: '#4c178c',
    950: '#000000',
  },
}
SCSS
$custom: #4c178c;
$custom-light: #855caf;
$custom-dark: #000000;
JSON
{
  "hex": "#4c178c",
  "rgb": {
    "r": 76,
    "g": 23,
    "b": 140
  },
  "hsl": {
    "h": 267.179,
    "s": 71.779,
    "l": 31.961
  },
  "oklch": {
    "l": 0.36517,
    "c": 0.17409,
    "h": 297.1
  },
  "luminance": 0.04043
}

Semantic roles & 50–950 ramp

primary
#4C178C
secondary
#85BF3F
accent
#EF399C
background
#F8F5FA
surface
#F0E9F5
border
#CBC5CF
text
#0C0410
muted
#7D797F

Preview Lab

Preview with #4C178C

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

Preview Lab → · Contrast checker → · Palette generator →

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