#040639#040639

#040639 is a very dark, moderate blue. Relative luminance 0.005; OKLCH L 17.4% C 0.095 H 268.9°. Best body text is #FFFFFF at 19.26:1 contrast (WCAG AA passes).

Color values

HEX#040639
RGBrgb(4, 6, 57)
HSLhsl(238, 87%, 12%)
HSVhsv(238, 93%, 22%)
CMYKcmyk(93%, 89.5%, 0%, 77.6%)
CIE-LABlab(4.08, 17.39, -31.38)
CIE-LCHlch(4.08, 35.87, 298.99°)
OKLaboklab(17.43% -0.0018 -0.0954)
OKLCHoklch(17.43% 0.095 268.9)
XYZxyz(0.8535, 0.4514, 3.9122)
Luminance0.0045 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#040639 #393704
analogous
#042139 #040639 #1D0439
triadic
#040639 #390406 #063904
tetradic
#040639 #390421 #393704 #04391D
square
#040639 #390421 #393704 #04391D
split-complementary
#040639 #391D04 #213904
monochromatic
#02031D #02031D #040639 #080C72 #0C12AB

Accessibility & contrast

On white

19.26
#040639 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.09
#040639 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #040639
19.26:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##040639#FFFFFF#000000##FFFFFF
##0406391.0019.261.0919.26
#FFFFFF19.261.0021.001.00
#0000001.0921.001.0021.00
##FFFFFF19.261.0021.001.00

Color blindness preview

Protanopia (red-blind)
#00113A
Deuteranopia (green-blind)
#000B38
Tritanopia (blue-blind)
#00151F
Achromatopsia (no color)
#0E0E0E

Design tokens & code

CSS
--color: #040639;
/* rgb */ color: rgb(4, 6, 57);
/* oklch */ color: oklch(17.4% 0.095 268.9);
Tailwind
colors: {
  custom: {
    50: '#4e4870',
    500: '#040639',
    950: '#000000',
  },
}
SCSS
$custom: #040639;
$custom-light: #4e4870;
$custom-dark: #000000;
JSON
{
  "hex": "#040639",
  "rgb": {
    "r": 4,
    "g": 6,
    "b": 57
  },
  "hsl": {
    "h": 237.736,
    "s": 86.885,
    "l": 11.961
  },
  "oklch": {
    "l": 0.17432,
    "c": 0.09546,
    "h": 268.9
  },
  "luminance": 0.00451
}

Semantic roles & 50–950 ramp

primary
#040639
secondary
#7B771E
accent
#F52BFD
background
#F4F4F6
surface
#E7E6EC
border
#C3C2C7
text
#020007
muted
#78777A

Preview Lab

Preview with #040639

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

Preview Lab → · Contrast checker → · Palette generator →

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