#5158BE#5158BE

#5158BE is a mid, vivid blue. Relative luminance 0.124; OKLCH L 51.0% C 0.158 H 276.3°. Best body text is #FFFFFF at 6.02:1 contrast (WCAG AA passes).

Color values

HEX#5158BE
RGBrgb(81, 88, 190)
HSLhsl(236, 46%, 53%)
HSVhsv(236, 57%, 75%)
CMYKcmyk(57.4%, 53.7%, 0%, 25.5%)
CIE-LABlab(41.92, 27.44, -54.71)
CIE-LCHlch(41.92, 61.20, 296.64°)
OKLaboklab(51% 0.0173 -0.1567)
OKLCHoklch(51% 0.158 276.3)
XYZxyz(16.1743, 12.4453, 50.2551)
Luminance0.1245 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5158BE #BEB751
analogous
#518EBE #5158BE #8051BE
triadic
#5158BE #BE5158 #58BE51
tetradic
#5158BE #BE518E #BEB751 #51BE80
square
#5158BE #BE518E #BEB751 #51BE80
split-complementary
#5158BE #BE8051 #8EBE51
monochromatic
#282D6C #393F99 #5158BE #7E83CF #AAAEDF

Accessibility & contrast

On white

6.02
#5158BE on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

3.49
#5158BE on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #5158BE
6.02:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5158BE#FFFFFF#000000##FFFFFF
##5158BE1.006.023.496.02
#FFFFFF6.021.0021.001.00
#0000003.4921.001.0021.00
##FFFFFF6.021.0021.001.00

Color blindness preview

Protanopia (red-blind)
#1968C2
Deuteranopia (green-blind)
#005EBC
Tritanopia (blue-blind)
#0C6F82
Achromatopsia (no color)
#636363

Design tokens & code

CSS
--color: #5158be;
/* rgb */ color: rgb(81, 88, 190);
/* oklch */ color: oklch(51.0% 0.158 276.3);
Tailwind
colors: {
  custom: {
    50: '#8b87d2',
    500: '#5158be',
    950: '#000000',
  },
}
SCSS
$custom: #5158be;
$custom-light: #8b87d2;
$custom-dark: #000000;
JSON
{
  "hex": "#5158be",
  "rgb": {
    "r": 81,
    "g": 88,
    "b": 190
  },
  "hsl": {
    "h": 236.147,
    "s": 45.607,
    "l": 53.137
  },
  "oklch": {
    "l": 0.51004,
    "c": 0.15762,
    "h": 276.3
  },
  "luminance": 0.12446
}

Semantic roles & 50–950 ramp

primary
#5158BE
secondary
#CDCA9E
accent
#CD53D5
background
#F9F8FD
surface
#F1EFFA
border
#CBCAD3
text
#0D0B14
muted
#7E7C83

Preview Lab

Preview with #5158BE

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

Preview Lab → · Contrast checker → · Palette generator →

#5158BE Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva