#171F7F#171F7F

#171F7F is a dark, vivid blue. Relative luminance 0.027; OKLCH L 31.4% C 0.158 H 269.7°. Best body text is #FFFFFF at 13.65:1 contrast (WCAG AA passes).

Color values

HEX#171F7F
RGBrgb(23, 31, 127)
HSLhsl(235, 69%, 29%)
HSVhsv(235, 82%, 50%)
CMYKcmyk(81.9%, 75.6%, 0%, 50.2%)
CIE-LABlab(18.77, 33.28, -54.39)
CIE-LCHlch(18.77, 63.77, 301.46°)
OKLaboklab(31.36% -0.0007 -0.1575)
OKLCHoklch(31.36% 0.158 269.7)
XYZxyz(4.6728, 2.6939, 20.3483)
Luminance0.0269 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#171F7F #7F7717
analogous
#17537F #171F7F #43177F
triadic
#171F7F #7F171F #1F7F17
tetradic
#171F7F #7F1753 #7F7717 #177F43
square
#171F7F #7F1753 #7F7717 #177F43
split-complementary
#171F7F #7F4317 #537F17
monochromatic
#05061A #0E124B #171F7F #202CB3 #3643DB

Accessibility & contrast

On white

13.65
#171F7F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.54
#171F7F on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #171F7F
13.65:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##171F7F#FFFFFF#000000##FFFFFF
##171F7F1.0013.651.5413.65
#FFFFFF13.651.0021.001.00
#0000001.5421.001.0021.00
##FFFFFF13.651.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003382
Deuteranopia (green-blind)
#00287D
Tritanopia (blue-blind)
#003B4D
Achromatopsia (no color)
#2E2E2E

Design tokens & code

CSS
--color: #171f7f;
/* rgb */ color: rgb(23, 31, 127);
/* oklch */ color: oklch(31.4% 0.158 269.7);
Tailwind
colors: {
  custom: {
    50: '#695ba5',
    500: '#171f7f',
    950: '#000000',
  },
}
SCSS
$custom: #171f7f;
$custom-light: #695ba5;
$custom-dark: #000000;
JSON
{
  "hex": "#171f7f",
  "rgb": {
    "r": 23,
    "g": 31,
    "b": 127
  },
  "hsl": {
    "h": 235.385,
    "s": 69.333,
    "l": 29.412
  },
  "oklch": {
    "l": 0.31362,
    "c": 0.15755,
    "h": 269.7
  },
  "luminance": 0.02694
}

Semantic roles & 50–950 ramp

primary
#171F7F
secondary
#B4AB3E
accent
#DF3CEC
background
#F6F5FA
surface
#ECE9F4
border
#C7C5CE
text
#07040F
muted
#7A797F

Preview Lab

Preview with #171F7F

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

Preview Lab → · Contrast checker → · Palette generator →

#171F7F Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva