#040D2E#040D2E

#040D2E is a very dark, moderate blue. Relative luminance 0.005; OKLCH L 17.6% C 0.068 H 265.9°. Best body text is #FFFFFF at 19.05:1 contrast (WCAG AA passes).

Color values

HEX#040D2E
RGBrgb(4, 13, 46)
HSLhsl(227, 84%, 10%)
HSVhsv(227, 91%, 18%)
CMYKcmyk(91.3%, 71.7%, 0%, 82%)
CIE-LABlab(4.61, 8.25, -22.39)
CIE-LCHlch(4.61, 23.87, 290.23°)
OKLaboklab(17.62% -0.0049 -0.0679)
OKLCHoklch(17.62% 0.068 265.9)
XYZxyz(0.6870, 0.5108, 2.6466)
Luminance0.0051 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#040D2E #2E2504
analogous
#04222E #040D2E #10042E
triadic
#040D2E #2E040D #0D2E04
tetradic
#040D2E #2E0422 #2E2504 #042E10
square
#040D2E #2E0422 #2E2504 #042E10
split-complementary
#040D2E #2E1004 #222E04
monochromatic
#02081C #02081C #040D2E #091D66 #0E2D9F

Accessibility & contrast

On white

19.05
#040D2E on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.10
#040D2E on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #040D2E
19.05:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##040D2E#FFFFFF#000000##FFFFFF
##040D2E1.0019.051.1019.05
#FFFFFF19.051.0021.001.00
#0000001.1021.001.0021.00
##FFFFFF19.051.0021.001.00

Color blindness preview

Protanopia (red-blind)
#00122F
Deuteranopia (green-blind)
#000E2D
Tritanopia (blue-blind)
#00151B
Achromatopsia (no color)
#101010

Design tokens & code

CSS
--color: #040d2e;
/* rgb */ color: rgb(4, 13, 46);
/* oklch */ color: oklch(17.6% 0.068 265.9);
Tailwind
colors: {
  custom: {
    50: '#4a4c67',
    500: '#040d2e',
    950: '#000000',
  },
}
SCSS
$custom: #040d2e;
$custom-light: #4a4c67;
$custom-dark: #000000;
JSON
{
  "hex": "#040d2e",
  "rgb": {
    "r": 4,
    "g": 13,
    "b": 46
  },
  "hsl": {
    "h": 227.143,
    "s": 84,
    "l": 9.804
  },
  "oklch": {
    "l": 0.17617,
    "c": 0.06804,
    "h": 265.9
  },
  "luminance": 0.00511
}

Semantic roles & 50–950 ramp

primary
#040D2E
secondary
#715F1D
accent
#CE2EFA
background
#F4F4F6
surface
#E7E7EB
border
#C3C3C6
text
#010106
muted
#77777A

Preview Lab

Preview with #040D2E

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

Preview Lab → · Contrast checker → · Palette generator →

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