#1D40A7#1D40A7

#1D40A7 is a dark, vivid blue. Relative luminance 0.067; OKLCH L 41.7% C 0.171 H 265.1°. Best body text is #FFFFFF at 8.96:1 contrast (WCAG AA passes).

Color values

HEX#1D40A7
RGBrgb(29, 64, 167)
HSLhsl(225, 70%, 38%)
HSVhsv(225, 83%, 65%)
CMYKcmyk(82.6%, 61.7%, 0%, 34.5%)
CIE-LABlab(31.15, 27.26, -58.71)
CIE-LCHlch(31.15, 64.73, 294.90°)
OKLaboklab(41.67% -0.0145 -0.1699)
OKLCHoklch(41.67% 0.171 265.1)
XYZxyz(9.3127, 6.7169, 37.3574)
Luminance0.0672 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#1D40A7 #A7841D
analogous
#1D85A7 #1D40A7 #3F1DA7
triadic
#1D40A7 #A71D40 #40A71D
tetradic
#1D40A7 #A71D85 #A7841D #1DA73F
square
#1D40A7 #A71D85 #A7841D #1DA73F
split-complementary
#1D40A7 #A73F1D #85A71D
monochromatic
#0B183F #142C73 #1D40A7 #2855DA #5C7EE3

Accessibility & contrast

On white

8.96
#1D40A7 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.34
#1D40A7 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #1D40A7
8.96:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##1D40A7#FFFFFF#000000##FFFFFF
##1D40A71.008.962.348.96
#FFFFFF8.961.0021.001.00
#0000002.3421.001.0021.00
##FFFFFF8.961.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0050AA
Deuteranopia (green-blind)
#0043A5
Tritanopia (blue-blind)
#005B6D
Achromatopsia (no color)
#494949

Design tokens & code

CSS
--color: #1d40a7;
/* rgb */ color: rgb(29, 64, 167);
/* oklch */ color: oklch(41.7% 0.171 265.1);
Tailwind
colors: {
  custom: {
    50: '#7274c2',
    500: '#1d40a7',
    950: '#000000',
  },
}
SCSS
$custom: #1d40a7;
$custom-light: #7274c2;
$custom-dark: #000000;
JSON
{
  "hex": "#1d40a7",
  "rgb": {
    "r": 29,
    "g": 64,
    "b": 167
  },
  "hsl": {
    "h": 224.783,
    "s": 70.408,
    "l": 38.431
  },
  "oklch": {
    "l": 0.41671,
    "c": 0.1705,
    "h": 265.1
  },
  "luminance": 0.06718
}

Semantic roles & 50–950 ramp

primary
#1D40A7
secondary
#C7AB59
accent
#C03BED
background
#F7F7FC
surface
#EEEDF8
border
#C9C8D1
text
#090812
muted
#7B7B81

Preview Lab

Preview with #1D40A7

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

Preview Lab → · Contrast checker → · Palette generator →

#1D40A7 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva