#40172F#40172F

#40172F is a dark, moderate pink. Relative luminance 0.019; OKLCH L 27.7% C 0.072 H 346.6°. Best body text is #FFFFFF at 15.20:1 contrast (WCAG AA passes).

Color values

HEX#40172F
RGBrgb(64, 23, 47)
HSLhsl(325, 47%, 17%)
HSVhsv(325, 64%, 25%)
CMYKcmyk(0%, 64.1%, 26.6%, 74.9%)
CIE-LABlab(15.00, 23.23, -6.30)
CIE-LCHlch(15.00, 24.07, 344.83°)
OKLaboklab(27.66% 0.0698 -0.0166)
OKLCHoklch(27.66% 0.072 346.6)
XYZxyz(2.9339, 1.9083, 2.9026)
Luminance0.0191 (WCAG relative)
Temperaturewarm
Familypink

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#40172F #174028
analogous
#3D1740 #40172F #40171B
triadic
#40172F #2F4017 #172F40
tetradic
#40172F #403D17 #174028 #171B40
square
#40172F #403D17 #174028 #171B40
split-complementary
#40172F #1B4017 #17403D
monochromatic
#170811 #170811 #40172F #6D2750 #9A3771

Accessibility & contrast

On white

15.20
#40172F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

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

Best text color

#FFFFFF on #40172F
15.20:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##40172F#FFFFFF#000000##FFFFFF
##40172F1.0015.201.3815.20
#FFFFFF15.201.0021.001.00
#0000001.3821.001.0021.00
##FFFFFF15.201.0021.001.00

Color blindness preview

Protanopia (red-blind)
#1B2130
Deuteranopia (green-blind)
#26282E
Tritanopia (blue-blind)
#441620
Achromatopsia (no color)
#262626

Design tokens & code

CSS
--color: #40172f;
/* rgb */ color: rgb(64, 23, 47);
/* oklch */ color: oklch(27.7% 0.072 346.6);
Tailwind
colors: {
  custom: {
    50: '#765667',
    500: '#40172f',
    950: '#000000',
  },
}
SCSS
$custom: #40172f;
$custom-light: #765667;
$custom-dark: #000000;
JSON
{
  "hex": "#40172f",
  "rgb": {
    "r": 64,
    "g": 23,
    "b": 47
  },
  "hsl": {
    "h": 324.878,
    "s": 47.126,
    "l": 17.059
  },
  "oklch": {
    "l": 0.27661,
    "c": 0.07179,
    "h": 346.6
  },
  "luminance": 0.01908
}

Semantic roles & 50–950 ramp

primary
#40172F
secondary
#3C7754
accent
#D78851
background
#F7F5F6
surface
#EDE9EB
border
#C8C5C6
text
#090306
muted
#7B787A

Preview Lab

Preview with #40172F

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

Preview Lab → · Contrast checker → · Palette generator →

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