Skip to content

#04080c

a deep, vivid blue · cool · closest name: black

RGB
4, 8, 12
HSL
210°, 50%, 3%
CMYK
67, 33, 0, 95
Luminance
0.0023

Every format

HEX#04080c
RGBrgb(4, 8, 12)
HSLhsl(210, 50%, 3%)
CMYKcmyk(67%, 33%, 0%, 95%)
LABlab(2.0 -0.5 -1.9)
LCHlch(2.0 2.0 256.2)
OKLCHoklch(0.131 0.013 241.4)

Copy-ready code

/* CSS */
color: #04080c;
background-color: #04080c;
/* Tailwind (arbitrary) */
class="text-[#04080c] bg-[#04080c]"
/* SCSS */
$brand: #04080c;
/* SwiftUI */
Color(red: 0.016, green: 0.031, blue: 0.047)
/* Android */
Color.parseColor("#04080c")

Accessibility — WCAG contrast

Aa
#04080c on white: 20.09:1
AA ✓ pass · AA-large · AAA
Aa
#04080c on black: 1.05:1
AA ✗ fail · AA-large · AAA
true color
protanopia
deuteranopia
tritanopia

RGB percentages

Red1.6%
Green3.1%
Blue4.7%

CMYK percentages

Cyan66.7%
Magenta33.3%
Yellow0.0%
Key (black)95.3%

Color previews

#04080c text on a black background

contrast 1.05:1

Card sample

#04080c text on a white background

contrast 20.09:1

Card sample

CSS3 live lab

Text font color

The quick brown fox

color: #04080c;
Background color
Panel with #04080c background
background-color: #04080c;
Text shadow — hex

Glowing headline

text-shadow: 2px 2px 8px #04080c;
Text shadow — RGB

Soft neon halo

text-shadow: 0 0 14px rgba(4, 8, 12, 0.45);
Div box shadow
Elevated card
box-shadow: 0 12px 32px -8px rgba(4, 8, 12, 0.45);
Border & gradient
Gradient panel
border: 3px solid #04080c;
background: linear-gradient(135deg, #04080c, #05040C);

Monochromatic scale

Palettes built from #04080c

Shades — darker

Tints — lighter

Hue & tone neighbors

Color harmonies

Nearest named colors

Work with #04080c in the Color Lab