#5162D2#5162D2

#5162D2 is a mid, vivid blue. Relative luminance 0.151; OKLCH L 54.4% C 0.172 H 272.8°. Best body text is #FFFFFF at 5.21:1 contrast (WCAG AA passes).

Color values

HEX#5162D2
RGBrgb(81, 98, 210)
HSLhsl(232, 59%, 57%)
HSVhsv(232, 61%, 82%)
CMYKcmyk(61.4%, 53.3%, 0%, 17.6%)
CIE-LABlab(45.82, 27.87, -59.95)
CIE-LCHlch(45.82, 66.11, 294.94°)
OKLaboklab(54.36% 0.0085 -0.172)
OKLCHoklch(54.36% 0.172 272.8)
XYZxyz(19.3900, 15.1362, 62.8600)
Luminance0.1514 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5162D2 #D2C151
analogous
#51A3D2 #5162D2 #8151D2
triadic
#5162D2 #D25162 #62D251
tetradic
#5162D2 #D251A3 #D2C151 #51D281
square
#5162D2 #D251A3 #D2C151 #51D281
split-complementary
#5162D2 #D28151 #A3D251
monochromatic
#233086 #2F41B7 #5162D2 #828EDF #B2BAEB

Accessibility & contrast

On white

5.21
#5162D2 on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

4.03
#5162D2 on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #5162D2
5.21:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5162D2#FFFFFF#000000##FFFFFF
##5162D21.005.214.035.21
#FFFFFF5.211.0021.001.00
#0000004.0321.001.0021.00
##FFFFFF5.211.0021.001.00

Color blindness preview

Protanopia (red-blind)
#1872D6
Deuteranopia (green-blind)
#0067D0
Tritanopia (blue-blind)
#007C90
Achromatopsia (no color)
#6C6C6C

Design tokens & code

CSS
--color: #5162d2;
/* rgb */ color: rgb(81, 98, 210);
/* oklch */ color: oklch(54.4% 0.172 272.8);
Tailwind
colors: {
  custom: {
    50: '#8e8ee0',
    500: '#5162d2',
    950: '#000000',
  },
}
SCSS
$custom: #5162d2;
$custom-light: #8e8ee0;
$custom-dark: #000000;
JSON
{
  "hex": "#5162d2",
  "rgb": {
    "r": 81,
    "g": 98,
    "b": 210
  },
  "hsl": {
    "h": 232.093,
    "s": 58.904,
    "l": 57.059
  },
  "oklch": {
    "l": 0.54365,
    "c": 0.17218,
    "h": 272.8
  },
  "luminance": 0.15138
}

Semantic roles & 50–950 ramp

primary
#5162D2
secondary
#DAD3A5
accent
#CD46E2
background
#F9F8FD
surface
#F2F0FB
border
#CCCBD4
text
#0D0C15
muted
#7E7D83

Preview Lab

Preview with #5162D2

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

Preview Lab → · Contrast checker → · Palette generator →

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