#4C1781#4C1781

#4C1781 is a dark, vivid violet. Relative luminance 0.037; OKLCH L 35.5% C 0.163 H 300.7°. Best body text is #FFFFFF at 12.02:1 contrast (WCAG AA passes).

Color values

HEX#4C1781
RGBrgb(76, 23, 129)
HSLhsl(270, 70%, 30%)
HSVhsv(270, 82%, 51%)
CMYKcmyk(41.1%, 82.2%, 0%, 49.4%)
CIE-LABlab(22.77, 44.91, -48.89)
CIE-LCHlch(22.77, 66.39, 312.57°)
OKLaboklab(35.48% 0.0829 -0.1398)
OKLCHoklch(35.48% 0.163 300.7)
XYZxyz(7.2484, 3.7342, 21.1035)
Luminance0.0373 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#4C1781 #4C8117
analogous
#171781 #4C1781 #811781
triadic
#4C1781 #814C17 #17814C
tetradic
#4C1781 #811717 #4C8117 #178181
square
#4C1781 #811717 #4C8117 #178181
split-complementary
#4C1781 #818117 #178117
monochromatic
#0F051A #2D0E4D #4C1781 #6B20B5 #8937DB

Accessibility & contrast

On white

12.02
#4C1781 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.75
#4C1781 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #4C1781
12.02:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##4C1781#FFFFFF#000000##FFFFFF
##4C17811.0012.021.7512.02
#FFFFFF12.021.0021.001.00
#0000001.7521.001.0021.00
##FFFFFF12.021.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003684
Deuteranopia (green-blind)
#00367F
Tritanopia (blue-blind)
#40344C
Achromatopsia (no color)
#363636

Design tokens & code

CSS
--color: #4c1781;
/* rgb */ color: rgb(76, 23, 129);
/* oklch */ color: oklch(35.5% 0.163 300.7);
Tailwind
colors: {
  custom: {
    50: '#845ba6',
    500: '#4c1781',
    950: '#000000',
  },
}
SCSS
$custom: #4c1781;
$custom-light: #845ba6;
$custom-dark: #000000;
JSON
{
  "hex": "#4c1781",
  "rgb": {
    "r": 76,
    "g": 23,
    "b": 129
  },
  "hsl": {
    "h": 270,
    "s": 69.737,
    "l": 29.804
  },
  "oklch": {
    "l": 0.35478,
    "c": 0.1625,
    "h": 300.7
  },
  "luminance": 0.03734
}

Semantic roles & 50–950 ramp

primary
#4C1781
secondary
#7AB53E
accent
#ED3B94
background
#F8F5FA
surface
#F0E9F4
border
#CBC5CE
text
#0B040F
muted
#7C797F

Preview Lab

Preview with #4C1781

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

Preview Lab → · Contrast checker → · Palette generator →

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