#1F178C#1F178C

#1F178C is a dark, vivid blue. Relative luminance 0.028; OKLCH L 32.2% C 0.179 H 272.9°. Best body text is #FFFFFF at 13.46:1 contrast (WCAG AA passes).

Color values

HEX#1F178C
RGBrgb(31, 23, 140)
HSLhsl(244, 72%, 32%)
HSVhsv(244, 84%, 55%)
CMYKcmyk(77.9%, 83.6%, 0%, 45.1%)
CIE-LABlab(19.21, 42.83, -61.84)
CIE-LCHlch(19.21, 75.22, 304.70°)
OKLaboklab(32.25% 0.009 -0.1789)
OKLCHoklch(32.25% 0.179 272.9)
XYZxyz(5.6035, 2.7970, 25.0504)
Luminance0.0280 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#1F178C #848C17
analogous
#17498C #1F178C #5A178C
triadic
#1F178C #8C1F17 #178C1F
tetradic
#1F178C #8C1749 #848C17 #178C5A
square
#1F178C #8C1749 #848C17 #178C5A
split-complementary
#1F178C #8C5A17 #498C17
monochromatic
#080623 #130E57 #1F178C #2B20C1 #493EDF

Accessibility & contrast

On white

13.46
#1F178C on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.56
#1F178C on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #1F178C
13.46:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##1F178C#FFFFFF#000000##FFFFFF
##1F178C1.0013.461.5613.46
#FFFFFF13.461.0021.001.00
#0000001.5621.001.0021.00
##FFFFFF13.461.0021.001.00

Color blindness preview

Protanopia (red-blind)
#00348F
Deuteranopia (green-blind)
#00298A
Tritanopia (blue-blind)
#003C53
Achromatopsia (no color)
#2F2F2F

Design tokens & code

CSS
--color: #1f178c;
/* rgb */ color: rgb(31, 23, 140);
/* oklch */ color: oklch(32.2% 0.179 272.9);
Tailwind
colors: {
  custom: {
    50: '#7058af',
    500: '#1f178c',
    950: '#000000',
  },
}
SCSS
$custom: #1f178c;
$custom-light: #7058af;
$custom-dark: #000000;
JSON
{
  "hex": "#1f178c",
  "rgb": {
    "r": 31,
    "g": 23,
    "b": 140
  },
  "hsl": {
    "h": 244.103,
    "s": 71.779,
    "l": 31.961
  },
  "oklch": {
    "l": 0.32245,
    "c": 0.17913,
    "h": 272.9
  },
  "luminance": 0.02798
}

Semantic roles & 50–950 ramp

primary
#1F178C
secondary
#B7BF3F
accent
#EF39E2
background
#F7F5FA
surface
#EDE9F5
border
#C8C5CF
text
#090311
muted
#7B7880

Preview Lab

Preview with #1F178C

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

Preview Lab → · Contrast checker → · Palette generator →

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