#040F35#040F35

#040F35 is a very dark, moderate blue. Relative luminance 0.006; OKLCH L 18.9% C 0.077 H 265.3°. Best body text is #FFFFFF at 18.67:1 contrast (WCAG AA passes).

Color values

HEX#040F35
RGBrgb(4, 15, 53)
HSLhsl(227, 86%, 11%)
HSVhsv(227, 92%, 21%)
CMYKcmyk(92.5%, 71.7%, 0%, 79.2%)
CIE-LABlab(5.64, 11.05, -25.93)
CIE-LCHlch(5.64, 28.19, 293.07°)
OKLaboklab(18.87% -0.0062 -0.0764)
OKLCHoklch(18.87% 0.077 265.3)
XYZxyz(0.8633, 0.6244, 3.4425)
Luminance0.0063 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#040F35 #352A04
analogous
#042735 #040F35 #110435
triadic
#040F35 #35040F #0F3504
tetradic
#040F35 #350427 #352A04 #043511
square
#040F35 #350427 #352A04 #043511
split-complementary
#040F35 #351104 #273504
monochromatic
#02081C #02081C #040F35 #081F6E #0D2FA7

Accessibility & contrast

On white

18.67
#040F35 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.13
#040F35 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #040F35
18.67:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##040F35#FFFFFF#000000##FFFFFF
##040F351.0018.671.1318.67
#FFFFFF18.671.0021.001.00
#0000001.1321.001.0021.00
##FFFFFF18.671.0021.001.00

Color blindness preview

Protanopia (red-blind)
#001536
Deuteranopia (green-blind)
#001034
Tritanopia (blue-blind)
#001920
Achromatopsia (no color)
#121212

Design tokens & code

CSS
--color: #040f35;
/* rgb */ color: rgb(4, 15, 53);
/* oklch */ color: oklch(18.9% 0.077 265.3);
Tailwind
colors: {
  custom: {
    50: '#4d4d6d',
    500: '#040f35',
    950: '#000000',
  },
}
SCSS
$custom: #040f35;
$custom-light: #4d4d6d;
$custom-dark: #000000;
JSON
{
  "hex": "#040f35",
  "rgb": {
    "r": 4,
    "g": 15,
    "b": 53
  },
  "hsl": {
    "h": 226.531,
    "s": 85.965,
    "l": 11.176
  },
  "oklch": {
    "l": 0.18874,
    "c": 0.07666,
    "h": 265.3
  },
  "luminance": 0.00625
}

Semantic roles & 50–950 ramp

primary
#040F35
secondary
#77631E
accent
#CD2CFC
background
#F4F4F6
surface
#E7E7EB
border
#C3C3C6
text
#020107
muted
#78777A

Preview Lab

Preview with #040F35

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

Preview Lab → · Contrast checker → · Palette generator →

#040F35 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva