#1F042F#1F042F

#1F042F is a very dark, moderate violet. Relative luminance 0.006; OKLCH L 19.1% C 0.083 H 309.6°. Best body text is #FFFFFF at 18.81:1 contrast (WCAG AA passes).

Color values

HEX#1F042F
RGBrgb(31, 4, 47)
HSLhsl(278, 84%, 10%)
HSVhsv(278, 91%, 18%)
CMYKcmyk(34%, 91.5%, 0%, 81.6%)
CIE-LABlab(5.27, 22.15, -21.95)
CIE-LCHlch(5.27, 31.19, 315.26°)
OKLaboklab(19.08% 0.0531 -0.0642)
OKLCHoklch(19.08% 0.083 309.6)
XYZxyz(1.1215, 0.5834, 2.7423)
Luminance0.0058 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#1F042F #142F04
analogous
#09042F #1F042F #2F042A
triadic
#1F042F #2F1F04 #042F1F
tetradic
#1F042F #2F0904 #142F04 #042A2F
square
#1F042F #2F0904 #142F04 #042A2F
split-complementary
#1F042F #2A2F04 #042F09
monochromatic
#13021C #13021C #1F042F #440967 #690EA0

Accessibility & contrast

On white

18.81
#1F042F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.12
#1F042F on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #1F042F
18.81:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##1F042F#FFFFFF#000000##FFFFFF
##1F042F1.0018.811.1218.81
#FFFFFF18.811.0021.001.00
#0000001.1221.001.0021.00
##FFFFFF18.811.0021.001.00

Color blindness preview

Protanopia (red-blind)
#001030
Deuteranopia (green-blind)
#00122E
Tritanopia (blue-blind)
#1D0E19
Achromatopsia (no color)
#121212

Design tokens & code

CSS
--color: #1f042f;
/* rgb */ color: rgb(31, 4, 47);
/* oklch */ color: oklch(19.1% 0.083 309.6);
Tailwind
colors: {
  custom: {
    50: '#5c4868',
    500: '#1f042f',
    950: '#000000',
  },
}
SCSS
$custom: #1f042f;
$custom-light: #5c4868;
$custom-dark: #000000;
JSON
{
  "hex": "#1f042f",
  "rgb": {
    "r": 31,
    "g": 4,
    "b": 47
  },
  "hsl": {
    "h": 277.674,
    "s": 84.314,
    "l": 10
  },
  "oklch": {
    "l": 0.1908,
    "c": 0.08333,
    "h": 309.6
  },
  "luminance": 0.00583
}

Semantic roles & 50–950 ramp

primary
#1F042F
secondary
#3D721D
accent
#FB2D7A
background
#F5F4F6
surface
#E9E6EB
border
#C5C2C6
text
#040006
muted
#79777A

Preview Lab

Preview with #1F042F

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

Preview Lab → · Contrast checker → · Palette generator →

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