#5162CF#5162CF

#5162CF is a mid, vivid blue. Relative luminance 0.150; OKLCH L 54.1% C 0.168 H 272.8°. Best body text is #FFFFFF at 5.25:1 contrast (WCAG AA passes).

Color values

HEX#5162CF
RGBrgb(81, 98, 207)
HSLhsl(232, 57%, 56%)
HSVhsv(232, 61%, 81%)
CMYKcmyk(60.9%, 52.7%, 0%, 18.8%)
CIE-LABlab(45.62, 26.86, -58.56)
CIE-LCHlch(45.62, 64.42, 294.64°)
OKLaboklab(54.15% 0.0083 -0.1679)
OKLCHoklch(54.15% 0.168 272.8)
XYZxyz(19.0198, 14.9881, 60.9101)
Luminance0.1499 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5162CF #CFBE51
analogous
#51A1CF #5162CF #7F51CF
triadic
#5162CF #CF5162 #62CF51
tetradic
#5162CF #CF51A1 #CFBE51 #51CF7F
square
#5162CF #CF51A1 #CFBE51 #51CF7F
split-complementary
#5162CF #CF7F51 #A1CF51
monochromatic
#243082 #3142B2 #5162CF #818DDC #B1B9E9

Accessibility & contrast

On white

5.25
#5162CF on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

4.00
#5162CF on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #5162CF
5.25:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5162CF#FFFFFF#000000##FFFFFF
##5162CF1.005.254.005.25
#FFFFFF5.251.0021.001.00
#0000004.0021.001.0021.00
##FFFFFF5.251.0021.001.00

Color blindness preview

Protanopia (red-blind)
#1E72D3
Deuteranopia (green-blind)
#0067CD
Tritanopia (blue-blind)
#007B8F
Achromatopsia (no color)
#6C6C6C

Design tokens & code

CSS
--color: #5162cf;
/* rgb */ color: rgb(81, 98, 207);
/* oklch */ color: oklch(54.1% 0.168 272.8);
Tailwind
colors: {
  custom: {
    50: '#8d8ede',
    500: '#5162cf',
    950: '#000000',
  },
}
SCSS
$custom: #5162cf;
$custom-light: #8d8ede;
$custom-dark: #000000;
JSON
{
  "hex": "#5162cf",
  "rgb": {
    "r": 81,
    "g": 98,
    "b": 207
  },
  "hsl": {
    "h": 231.905,
    "s": 56.757,
    "l": 56.471
  },
  "oklch": {
    "l": 0.54149,
    "c": 0.16809,
    "h": 272.8
  },
  "luminance": 0.1499
}

Semantic roles & 50–950 ramp

primary
#5162CF
secondary
#D8D1A4
accent
#CB48E0
background
#F9F8FD
surface
#F2F0FB
border
#CCCBD4
text
#0D0C15
muted
#7E7D83

Preview Lab

Preview with #5162CF

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

Preview Lab → · Contrast checker → · Palette generator →

#5162CF Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva