#40172C#40172C

#40172C is a dark, moderate pink. Relative luminance 0.019; OKLCH L 27.5% C 0.070 H 350.7°. Best body text is #FFFFFF at 15.25:1 contrast (WCAG AA passes).

Color values

HEX#40172C
RGBrgb(64, 23, 44)
HSLhsl(329, 47%, 17%)
HSVhsv(329, 64%, 25%)
CMYKcmyk(0%, 64.1%, 31.2%, 74.9%)
CIE-LABlab(14.87, 22.73, -4.33)
CIE-LCHlch(14.87, 23.14, 349.22°)
OKLaboklab(27.53% 0.0688 -0.0112)
OKLCHoklch(27.53% 0.07 350.7)
XYZxyz(2.8755, 1.8849, 2.5948)
Luminance0.0188 (WCAG relative)
Temperaturewarm
Familypink

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#40172C #17402B
analogous
#401740 #40172C #401718
triadic
#40172C #2C4017 #172C40
tetradic
#40172C #404017 #17402B #171840
square
#40172C #404017 #17402B #171840
split-complementary
#40172C #184017 #174040
monochromatic
#17080F #17080F #40172C #6D274B #9A376A

Accessibility & contrast

On white

15.25
#40172C on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.38
#40172C on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #40172C
15.25:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##40172C#FFFFFF#000000##FFFFFF
##40172C1.0015.251.3815.25
#FFFFFF15.251.0021.001.00
#0000001.3821.001.0021.00
##FFFFFF15.251.0021.001.00

Color blindness preview

Protanopia (red-blind)
#1C212D
Deuteranopia (green-blind)
#27282B
Tritanopia (blue-blind)
#45151F
Achromatopsia (no color)
#252525

Design tokens & code

CSS
--color: #40172c;
/* rgb */ color: rgb(64, 23, 44);
/* oklch */ color: oklch(27.5% 0.070 350.7);
Tailwind
colors: {
  custom: {
    50: '#775665',
    500: '#40172c',
    950: '#000000',
  },
}
SCSS
$custom: #40172c;
$custom-light: #775665;
$custom-dark: #000000;
JSON
{
  "hex": "#40172c",
  "rgb": {
    "r": 64,
    "g": 23,
    "b": 44
  },
  "hsl": {
    "h": 329.268,
    "s": 47.126,
    "l": 17.059
  },
  "oklch": {
    "l": 0.27525,
    "c": 0.0697,
    "h": 350.7
  },
  "luminance": 0.01885
}

Semantic roles & 50–950 ramp

primary
#40172C
secondary
#3C7759
accent
#D79251
background
#F7F5F6
surface
#EDE9EB
border
#C8C5C6
text
#090305
muted
#7B787A

Preview Lab

Preview with #40172C

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

Preview Lab → · Contrast checker → · Palette generator →

#40172C Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva