#040547#040547

#040547 is a very dark, moderate blue. Relative luminance 0.006; OKLCH L 19.3% C 0.116 H 267.7°. Best body text is #FFFFFF at 18.79:1 contrast (WCAG AA passes).

Color values

HEX#040547
RGBrgb(4, 5, 71)
HSLhsl(239, 89%, 15%)
HSVhsv(239, 94%, 28%)
CMYKcmyk(94.4%, 93%, 0%, 72.2%)
CIE-LABlab(5.32, 25.84, -39.38)
CIE-LCHlch(5.32, 47.10, 303.28°)
OKLaboklab(19.26% -0.0046 -0.1159)
OKLCHoklch(19.26% 0.116 267.7)
XYZxyz(1.2413, 0.5891, 6.0083)
Luminance0.0059 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#040547 #474604
analogous
#042747 #040547 #240447
triadic
#040547 #470405 #054704
tetradic
#040547 #470427 #474604 #044724
square
#040547 #470427 #474604 #044724
split-complementary
#040547 #472404 #274704
monochromatic
#02021D #02021D #040547 #070981 #0B0DBB

Accessibility & contrast

On white

18.79
#040547 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.12
#040547 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #040547
18.79:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##040547#FFFFFF#000000##FFFFFF
##0405471.0018.791.1218.79
#FFFFFF18.791.0021.001.00
#0000001.1221.001.0021.00
##FFFFFF18.791.0021.001.00

Color blindness preview

Protanopia (red-blind)
#001549
Deuteranopia (green-blind)
#000E46
Tritanopia (blue-blind)
#001A27
Achromatopsia (no color)
#121212

Design tokens & code

CSS
--color: #040547;
/* rgb */ color: rgb(4, 5, 71);
/* oklch */ color: oklch(19.3% 0.116 267.7);
Tailwind
colors: {
  custom: {
    50: '#54477b',
    500: '#040547',
    950: '#000000',
  },
}
SCSS
$custom: #040547;
$custom-light: #54477b;
$custom-dark: #000000;
JSON
{
  "hex": "#040547",
  "rgb": {
    "r": 4,
    "g": 5,
    "b": 71
  },
  "hsl": {
    "h": 239.104,
    "s": 89.333,
    "l": 14.706
  },
  "oklch": {
    "l": 0.1926,
    "c": 0.11596,
    "h": 267.7
  },
  "luminance": 0.00589
}

Semantic roles & 50–950 ramp

primary
#040547
secondary
#88861F
accent
#FC29FF
background
#F5F4F7
surface
#E9E6EE
border
#C5C2C9
text
#030009
muted
#78777B

Preview Lab

Preview with #040547

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

Preview Lab → · Contrast checker → · Palette generator →

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