#1F042C#1F042C

#1F042C is a very dark, moderate purple. Relative luminance 0.006; OKLCH L 18.8% C 0.080 H 312.4°. Best body text is #FFFFFF at 18.88:1 contrast (WCAG AA passes).

Color values

HEX#1F042C
RGBrgb(31, 4, 44)
HSLhsl(281, 83%, 9%)
HSVhsv(281, 91%, 17%)
CMYKcmyk(29.5%, 90.9%, 0%, 82.7%)
CIE-LABlab(5.06, 21.05, -20.04)
CIE-LCHlch(5.06, 29.06, 316.41°)
OKLaboklab(18.79% 0.0539 -0.0589)
OKLCHoklch(18.79% 0.08 312.4)
XYZxyz(1.0630, 0.5600, 2.4345)
Luminance0.0056 (WCAG relative)
Temperaturecool
Familypurple

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#1F042C #112C04
analogous
#0B042C #1F042C #2C0425
triadic
#1F042C #2C1F04 #042C1F
tetradic
#1F042C #2C0B04 #112C04 #04252C
square
#1F042C #2C0B04 #112C04 #04252C
split-complementary
#1F042C #252C04 #042C0B
monochromatic
#14031C #14031C #1F042C #470964 #6E0E9C

Accessibility & contrast

On white

18.88
#1F042C on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.11
#1F042C on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #1F042C
18.88:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##1F042C#FFFFFF#000000##FFFFFF
##1F042C1.0018.881.1118.88
#FFFFFF18.881.0021.001.00
#0000001.1121.001.0021.00
##FFFFFF18.881.0021.001.00

Color blindness preview

Protanopia (red-blind)
#00102D
Deuteranopia (green-blind)
#01122B
Tritanopia (blue-blind)
#1D0C17
Achromatopsia (no color)
#111111

Design tokens & code

CSS
--color: #1f042c;
/* rgb */ color: rgb(31, 4, 44);
/* oklch */ color: oklch(18.8% 0.080 312.4);
Tailwind
colors: {
  custom: {
    50: '#5c4865',
    500: '#1f042c',
    950: '#000000',
  },
}
SCSS
$custom: #1f042c;
$custom-light: #5c4865;
$custom-dark: #000000;
JSON
{
  "hex": "#1f042c",
  "rgb": {
    "r": 31,
    "g": 4,
    "b": 44
  },
  "hsl": {
    "h": 280.5,
    "s": 83.333,
    "l": 9.412
  },
  "oklch": {
    "l": 0.18793,
    "c": 0.07987,
    "h": 312.4
  },
  "luminance": 0.0056
}

Semantic roles & 50–950 ramp

primary
#1F042C
secondary
#386F1D
accent
#FA2E70
background
#F5F4F6
surface
#E9E6EB
border
#C5C2C6
text
#040005
muted
#79777A

Preview Lab

Preview with #1F042C

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

Preview Lab → · Contrast checker → · Palette generator →

#1F042C Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva