#4D168E#4D168E

#4D168E is a dark, vivid violet. Relative luminance 0.041; OKLCH L 36.7% C 0.177 H 297.1°. Best body text is #FFFFFF at 11.53:1 contrast (WCAG AA passes).

Color values

HEX#4D168E
RGBrgb(77, 22, 142)
HSLhsl(268, 73%, 32%)
HSVhsv(268, 85%, 56%)
CMYKcmyk(45.8%, 84.5%, 0%, 44.3%)
CIE-LABlab(24.01, 48.72, -55.00)
CIE-LCHlch(24.01, 73.48, 311.53°)
OKLaboklab(36.74% 0.0808 -0.1576)
OKLCHoklch(36.74% 0.177 297.1)
XYZxyz(8.2287, 4.1044, 25.9446)
Luminance0.0411 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#4D168E #578E16
analogous
#161B8E #4D168E #89168E
triadic
#4D168E #8E4D16 #168E4D
tetradic
#4D168E #8E161B #578E16 #168E89
square
#4D168E #8E161B #578E16 #168E89
split-complementary
#4D168E #8E8916 #1B8E16
monochromatic
#140624 #300E59 #4D168E #6A1EC3 #883DE1

Accessibility & contrast

On white

11.53
#4D168E on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.82
#4D168E on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #4D168E
11.53:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##4D168E#FFFFFF#000000##FFFFFF
##4D168E1.0011.531.8211.53
#FFFFFF11.531.0021.001.00
#0000001.8221.001.0021.00
##FFFFFF11.531.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003A91
Deuteranopia (green-blind)
#00388C
Tritanopia (blue-blind)
#3B3954
Achromatopsia (no color)
#393939

Design tokens & code

CSS
--color: #4d168e;
/* rgb */ color: rgb(77, 22, 142);
/* oklch */ color: oklch(36.7% 0.177 297.1);
Tailwind
colors: {
  custom: {
    50: '#865cb0',
    500: '#4d168e',
    950: '#000000',
  },
}
SCSS
$custom: #4d168e;
$custom-light: #865cb0;
$custom-dark: #000000;
JSON
{
  "hex": "#4d168e",
  "rgb": {
    "r": 77,
    "g": 22,
    "b": 142
  },
  "hsl": {
    "h": 267.5,
    "s": 73.171,
    "l": 32.157
  },
  "oklch": {
    "l": 0.36745,
    "c": 0.17715,
    "h": 297.1
  },
  "luminance": 0.04105
}

Semantic roles & 50–950 ramp

primary
#4D168E
secondary
#85C13F
accent
#F0389C
background
#F8F5FB
surface
#F0E9F6
border
#CBC5D0
text
#0C0411
muted
#7D7980

Preview Lab

Preview with #4D168E

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

Preview Lab → · Contrast checker → · Palette generator →

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