#040A2F#040A2F

#040A2F is a very dark, moderate blue. Relative luminance 0.004; OKLCH L 17.0% C 0.074 H 268.0°. Best body text is #FFFFFF at 19.27:1 contrast (WCAG AA passes).

Color values

HEX#040A2F
RGBrgb(4, 10, 47)
HSLhsl(232, 84%, 10%)
HSVhsv(232, 91%, 18%)
CMYKcmyk(91.5%, 78.7%, 0%, 81.6%)
CIE-LABlab(4.05, 10.06, -24.04)
CIE-LCHlch(4.05, 26.06, 292.71°)
OKLaboklab(17.02% -0.0026 -0.0742)
OKLCHoklch(17.02% 0.074 268)
XYZxyz(0.6715, 0.4481, 2.7399)
Luminance0.0045 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#040A2F #2F2904
analogous
#041F2F #040A2F #14042F
triadic
#040A2F #2F040A #0A2F04
tetradic
#040A2F #2F041F #2F2904 #042F14
square
#040A2F #2F041F #2F2904 #042F14
split-complementary
#040A2F #2F1404 #1F2F04
monochromatic
#02061C #02061C #040A2F #091667 #0E22A0

Accessibility & contrast

On white

19.27
#040A2F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

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

Best text color

#FFFFFF on #040A2F
19.27:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##040A2F#FFFFFF#000000##FFFFFF
##040A2F1.0019.271.0919.27
#FFFFFF19.271.0021.001.00
#0000001.0921.001.0021.00
##FFFFFF19.271.0021.001.00

Color blindness preview

Protanopia (red-blind)
#001030
Deuteranopia (green-blind)
#000C2E
Tritanopia (blue-blind)
#00141B
Achromatopsia (no color)
#0E0E0E

Design tokens & code

CSS
--color: #040a2f;
/* rgb */ color: rgb(4, 10, 47);
/* oklch */ color: oklch(17.0% 0.074 268.0);
Tailwind
colors: {
  custom: {
    50: '#4a4b68',
    500: '#040a2f',
    950: '#000000',
  },
}
SCSS
$custom: #040a2f;
$custom-light: #4a4b68;
$custom-dark: #000000;
JSON
{
  "hex": "#040a2f",
  "rgb": {
    "r": 4,
    "g": 10,
    "b": 47
  },
  "hsl": {
    "h": 231.628,
    "s": 84.314,
    "l": 10
  },
  "oklch": {
    "l": 0.17017,
    "c": 0.07425,
    "h": 268
  },
  "luminance": 0.00448
}

Semantic roles & 50–950 ramp

primary
#040A2F
secondary
#72661D
accent
#DE2DFB
background
#F4F4F6
surface
#E7E7EB
border
#C3C3C6
text
#010106
muted
#77777A

Preview Lab

Preview with #040A2F

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

Preview Lab → · Contrast checker → · Palette generator →

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