#040D27#040D27

#040D27 is a very dark, muted blue. Relative luminance 0.005; OKLCH L 16.9% C 0.056 H 264.4°. Best body text is #FFFFFF at 19.23:1 contrast (WCAG AA passes).

Color values

HEX#040D27
RGBrgb(4, 13, 39)
HSLhsl(225, 81%, 8%)
HSVhsv(225, 90%, 15%)
CMYKcmyk(89.7%, 66.7%, 0%, 84.7%)
CIE-LABlab(4.16, 5.03, -17.83)
CIE-LCHlch(4.16, 18.52, 285.76°)
OKLaboklab(16.89% -0.0054 -0.0556)
OKLCHoklch(16.89% 0.056 264.4)
XYZxyz(0.5601, 0.4601, 1.9783)
Luminance0.0046 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#040D27 #271E04
analogous
#041E27 #040D27 #0C0427
triadic
#040D27 #27040D #0D2704
tetradic
#040D27 #27041E #271E04 #04270C
square
#040D27 #27041E #271E04 #04270C
split-complementary
#040D27 #270C04 #1E2704
monochromatic
#03091C #03091C #040D27 #0A205F #0F3296

Accessibility & contrast

On white

19.23
#040D27 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.09
#040D27 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #040D27
19.23:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##040D27#FFFFFF#000000##FFFFFF
##040D271.0019.231.0919.23
#FFFFFF19.231.0021.001.00
#0000001.0921.001.0021.00
##FFFFFF19.231.0021.001.00

Color blindness preview

Protanopia (red-blind)
#011028
Deuteranopia (green-blind)
#000D26
Tritanopia (blue-blind)
#001318
Achromatopsia (no color)
#0F0F0F

Design tokens & code

CSS
--color: #040d27;
/* rgb */ color: rgb(4, 13, 39);
/* oklch */ color: oklch(16.9% 0.056 264.4);
Tailwind
colors: {
  custom: {
    50: '#494c61',
    500: '#040d27',
    950: '#000000',
  },
}
SCSS
$custom: #040d27;
$custom-light: #494c61;
$custom-dark: #000000;
JSON
{
  "hex": "#040d27",
  "rgb": {
    "r": 4,
    "g": 13,
    "b": 39
  },
  "hsl": {
    "h": 224.571,
    "s": 81.395,
    "l": 8.431
  },
  "oklch": {
    "l": 0.16886,
    "c": 0.05586,
    "h": 264.4
  },
  "luminance": 0.0046
}

Semantic roles & 50–950 ramp

primary
#040D27
secondary
#6A561D
accent
#C430F8
background
#F4F4F5
surface
#E7E7E9
border
#C3C3C5
text
#010105
muted
#777779

Preview Lab

Preview with #040D27

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

Preview Lab → · Contrast checker → · Palette generator →

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