#040018#040018

#040018 is a very dark, moderate violet. Relative luminance 0.001; OKLCH L 10.5% C 0.061 H 285.4°. Best body text is #FFFFFF at 20.62:1 contrast (WCAG AA passes).

Color values

HEX#040018
RGBrgb(4, 0, 24)
HSLhsl(250, 100%, 5%)
HSVhsv(250, 100%, 9%)
CMYKcmyk(83.3%, 100%, 0%, 90.6%)
CIE-LABlab(0.83, 5.23, -11.02)
CIE-LCHlch(0.83, 12.20, 295.40°)
OKLaboklab(10.53% 0.0163 -0.0592)
OKLCHoklch(10.53% 0.061 285.4)
XYZxyz(0.2149, 0.0917, 0.8704)
Luminance0.0009 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#040018 #141800
analogous
#000818 #040018 #100018
triadic
#040018 #180400 #001804
tetradic
#040018 #180008 #141800 #001810
square
#040018 #180008 #141800 #001810
split-complementary
#040018 #181000 #081800
monochromatic
#05001F #05001F #05001F #0E0055 #180092

Accessibility & contrast

On white

20.62
#040018 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.02
#040018 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #040018
20.62:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##040018#FFFFFF#000000##FFFFFF
##0400181.0020.621.0220.62
#FFFFFF20.621.0021.001.00
#0000001.0221.001.0021.00
##FFFFFF20.621.0021.001.00

Color blindness preview

Protanopia (red-blind)
#000319
Deuteranopia (green-blind)
#000317
Tritanopia (blue-blind)
#000409
Achromatopsia (no color)
#030303

Design tokens & code

CSS
--color: #040018;
/* rgb */ color: rgb(4, 0, 24);
/* oklch */ color: oklch(10.5% 0.061 285.4);
Tailwind
colors: {
  custom: {
    50: '#484754',
    500: '#040018',
    950: '#000000',
  },
}
SCSS
$custom: #040018;
$custom-light: #484754;
$custom-dark: #000000;
JSON
{
  "hex": "#040018",
  "rgb": {
    "r": 4,
    "g": 0,
    "b": 24
  },
  "hsl": {
    "h": 250,
    "s": 100,
    "l": 4.706
  },
  "oklch": {
    "l": 0.10532,
    "c": 0.06139,
    "h": 285.4
  },
  "luminance": 0.00092
}

Semantic roles & 50–950 ramp

primary
#040018
secondary
#556211
accent
#FF29DB
background
#F4F3F4
surface
#E6E5E7
border
#C2C1C3
text
#000002
muted
#777778

Preview Lab

Preview with #040018

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

Preview Lab → · Contrast checker → · Palette generator →

#040018 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva