#040828#040828

#040828 is a very dark, moderate blue. Relative luminance 0.004; OKLCH L 15.7% C 0.066 H 269.5°. Best body text is #FFFFFF at 19.62:1 contrast (WCAG AA passes).

Color values

HEX#040828
RGBrgb(4, 8, 40)
HSLhsl(233, 82%, 9%)
HSVhsv(233, 90%, 16%)
CMYKcmyk(90%, 80%, 0%, 84.3%)
CIE-LABlab(3.19, 7.56, -20.11)
CIE-LCHlch(3.19, 21.48, 290.62°)
OKLaboklab(15.69% -0.0006 -0.0658)
OKLCHoklch(15.69% 0.066 269.5)
XYZxyz(0.5198, 0.3526, 2.0477)
Luminance0.0035 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#040828 #282404
analogous
#041A28 #040828 #120428
triadic
#040828 #280408 #082804
tetradic
#040828 #28041A #282404 #042812
square
#040828 #28041A #282404 #042812
split-complementary
#040828 #281204 #1A2804
monochromatic
#03061C #03061C #040828 #0A1360 #0F1E97

Accessibility & contrast

On white

19.62
#040828 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.07
#040828 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #040828
19.62:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##040828#FFFFFF#000000##FFFFFF
##0408281.0019.621.0719.62
#FFFFFF19.621.0021.001.00
#0000001.0721.001.0021.00
##FFFFFF19.621.0021.001.00

Color blindness preview

Protanopia (red-blind)
#000D29
Deuteranopia (green-blind)
#000A27
Tritanopia (blue-blind)
#001016
Achromatopsia (no color)
#0C0C0C

Design tokens & code

CSS
--color: #040828;
/* rgb */ color: rgb(4, 8, 40);
/* oklch */ color: oklch(15.7% 0.066 269.5);
Tailwind
colors: {
  custom: {
    50: '#494a62',
    500: '#040828',
    950: '#000000',
  },
}
SCSS
$custom: #040828;
$custom-light: #494a62;
$custom-dark: #000000;
JSON
{
  "hex": "#040828",
  "rgb": {
    "r": 4,
    "g": 8,
    "b": 40
  },
  "hsl": {
    "h": 233.333,
    "s": 81.818,
    "l": 8.627
  },
  "oklch": {
    "l": 0.15694,
    "c": 0.06576,
    "h": 269.5
  },
  "luminance": 0.00353
}

Semantic roles & 50–950 ramp

primary
#040828
secondary
#6B621D
accent
#E230F8
background
#F4F4F5
surface
#E7E7EA
border
#C3C3C6
text
#010105
muted
#777779

Preview Lab

Preview with #040828

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

Preview Lab → · Contrast checker → · Palette generator →

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