#1F127F#1F127F

#1F127F is a dark, vivid blue. Relative luminance 0.023; OKLCH L 30.1% C 0.167 H 274.9°. Best body text is #FFFFFF at 14.47:1 contrast (WCAG AA passes).

Color values

HEX#1F127F
RGBrgb(31, 18, 127)
HSLhsl(247, 75%, 28%)
HSVhsv(247, 86%, 50%)
CMYKcmyk(75.6%, 85.8%, 0%, 50.2%)
CIE-LABlab(16.78, 41.08, -57.68)
CIE-LCHlch(16.78, 70.81, 305.46°)
OKLaboklab(30.09% 0.0142 -0.1668)
OKLCHoklch(30.09% 0.167 274.9)
XYZxyz(4.6109, 2.2558, 20.2670)
Luminance0.0226 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#1F127F #727F12
analogous
#123B7F #1F127F #55127F
triadic
#1F127F #7F1F12 #127F1F
tetradic
#1F127F #7F123B #727F12 #127F55
square
#1F127F #7F123B #727F12 #127F55
split-complementary
#1F127F #7F5512 #3B7F12
monochromatic
#07041B #120A49 #1F127F #2C1AB5 #402BE1

Accessibility & contrast

On white

14.47
#1F127F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.45
#1F127F on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #1F127F
14.47:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##1F127F#FFFFFF#000000##FFFFFF
##1F127F1.0014.471.4514.47
#FFFFFF14.471.0021.001.00
#0000001.4521.001.0021.00
##FFFFFF14.471.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002E82
Deuteranopia (green-blind)
#00247D
Tritanopia (blue-blind)
#00354A
Achromatopsia (no color)
#292929

Design tokens & code

CSS
--color: #1f127f;
/* rgb */ color: rgb(31, 18, 127);
/* oklch */ color: oklch(30.1% 0.167 274.9);
Tailwind
colors: {
  custom: {
    50: '#6d54a5',
    500: '#1f127f',
    950: '#000000',
  },
}
SCSS
$custom: #1f127f;
$custom-light: #6d54a5;
$custom-dark: #000000;
JSON
{
  "hex": "#1f127f",
  "rgb": {
    "r": 31,
    "g": 18,
    "b": 127
  },
  "hsl": {
    "h": 247.156,
    "s": 75.172,
    "l": 28.431
  },
  "oklch": {
    "l": 0.30093,
    "c": 0.16737,
    "h": 274.9
  },
  "luminance": 0.02256
}

Semantic roles & 50–950 ramp

primary
#1F127F
secondary
#A6B538
accent
#F236DB
background
#F7F5FA
surface
#EDE9F4
border
#C8C5CE
text
#08030F
muted
#7B787F

Preview Lab

Preview with #1F127F

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

Preview Lab → · Contrast checker → · Palette generator →

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