#12157F#12157F

#12157F is a dark, vivid blue. Relative luminance 0.022; OKLCH L 29.7% C 0.169 H 269.0°. Best body text is #FFFFFF at 14.59:1 contrast (WCAG AA passes).

Color values

HEX#12157F
RGBrgb(18, 21, 127)
HSLhsl(238, 75%, 28%)
HSVhsv(238, 86%, 50%)
CMYKcmyk(85.8%, 83.5%, 0%, 50.2%)
CIE-LABlab(16.49, 38.78, -58.19)
CIE-LCHlch(16.49, 69.92, 303.68°)
OKLaboklab(29.68% -0.0029 -0.1685)
OKLCHoklch(29.68% 0.169 269)
XYZxyz(4.3471, 2.1967, 20.2695)
Luminance0.0220 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#12157F #7F7C12
analogous
#124B7F #12157F #45127F
triadic
#12157F #7F1215 #157F12
tetradic
#12157F #7F124B #7F7C12 #127F45
square
#12157F #7F124B #7F7C12 #127F45
split-complementary
#12157F #7F4512 #4B7F12
monochromatic
#04041B #0A0C49 #12157F #1A1EB5 #2B30E1

Accessibility & contrast

On white

14.59
#12157F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.44
#12157F on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #12157F
14.59:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##12157F#FFFFFF#000000##FFFFFF
##12157F1.0014.591.4414.59
#FFFFFF14.591.0021.001.00
#0000001.4421.001.0021.00
##FFFFFF14.591.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002E82
Deuteranopia (green-blind)
#00237D
Tritanopia (blue-blind)
#00374B
Achromatopsia (no color)
#292929

Design tokens & code

CSS
--color: #12157f;
/* rgb */ color: rgb(18, 21, 127);
/* oklch */ color: oklch(29.7% 0.169 269.0);
Tailwind
colors: {
  custom: {
    50: '#6855a5',
    500: '#12157f',
    950: '#000000',
  },
}
SCSS
$custom: #12157f;
$custom-light: #6855a5;
$custom-dark: #000000;
JSON
{
  "hex": "#12157f",
  "rgb": {
    "r": 18,
    "g": 21,
    "b": 127
  },
  "hsl": {
    "h": 238.349,
    "s": 75.172,
    "l": 28.431
  },
  "oklch": {
    "l": 0.2968,
    "c": 0.16854,
    "h": 269
  },
  "luminance": 0.02197
}

Semantic roles & 50–950 ramp

primary
#12157F
secondary
#B5B138
accent
#ED36F2
background
#F6F5FA
surface
#ECE9F4
border
#C7C5CE
text
#08030F
muted
#7A787F

Preview Lab

Preview with #12157F

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

Preview Lab → · Contrast checker → · Palette generator →

#12157F Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva