#40173D#40173D

#40173D is a dark, moderate purple. Relative luminance 0.020; OKLCH L 28.4% C 0.084 H 330.4°. Best body text is #FFFFFF at 14.91:1 contrast (WCAG AA passes).

Color values

HEX#40173D
RGBrgb(64, 23, 61)
HSLhsl(304, 47%, 17%)
HSVhsv(304, 64%, 25%)
CMYKcmyk(0%, 64.1%, 4.7%, 74.9%)
CIE-LABlab(15.70, 25.89, -15.19)
CIE-LCHlch(15.70, 30.01, 329.59°)
OKLaboklab(28.4% 0.0733 -0.0416)
OKLCHoklch(28.4% 0.084 330.4)
XYZxyz(3.2630, 2.0399, 4.6359)
Luminance0.0204 (WCAG relative)
Temperatureneutral
Familypurple

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#40173D #17401A
analogous
#2F1740 #40173D #401729
triadic
#40173D #3D4017 #173D40
tetradic
#40173D #402F17 #17401A #172940
square
#40173D #402F17 #17401A #172940
split-complementary
#40173D #294017 #17402F
monochromatic
#170815 #170815 #40173D #6D2768 #9A3793

Accessibility & contrast

On white

14.91
#40173D on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.41
#40173D on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #40173D
14.91:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##40173D#FFFFFF#000000##FFFFFF
##40173D1.0014.911.4114.91
#FFFFFF14.911.0021.001.00
#0000001.4121.001.0021.00
##FFFFFF14.911.0021.001.00

Color blindness preview

Protanopia (red-blind)
#15243E
Deuteranopia (green-blind)
#21293C
Tritanopia (blue-blind)
#431B27
Achromatopsia (no color)
#272727

Design tokens & code

CSS
--color: #40173d;
/* rgb */ color: rgb(64, 23, 61);
/* oklch */ color: oklch(28.4% 0.084 330.4);
Tailwind
colors: {
  custom: {
    50: '#765772',
    500: '#40173d',
    950: '#000000',
  },
}
SCSS
$custom: #40173d;
$custom-light: #765772;
$custom-dark: #000000;
JSON
{
  "hex": "#40173d",
  "rgb": {
    "r": 64,
    "g": 23,
    "b": 61
  },
  "hsl": {
    "h": 304.39,
    "s": 47.126,
    "l": 17.059
  },
  "oklch": {
    "l": 0.28404,
    "c": 0.08432,
    "h": 330.4
  },
  "luminance": 0.0204
}

Semantic roles & 50–950 ramp

primary
#40173D
secondary
#3C7740
accent
#D75B51
background
#F7F5F6
surface
#EDE9EC
border
#C8C5C7
text
#090308
muted
#7B787B

Preview Lab

Preview with #40173D

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

Preview Lab → · Contrast checker → · Palette generator →

#40173D Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva