#5142C4#5142C4

#5142C4 is a mid, vivid blue. Relative luminance 0.096; OKLCH L 47.7% C 0.194 H 281.4°. Best body text is #FFFFFF at 7.18:1 contrast (WCAG AA passes).

Color values

HEX#5142C4
RGBrgb(81, 66, 196)
HSLhsl(247, 52%, 51%)
HSVhsv(247, 66%, 77%)
CMYKcmyk(58.7%, 66.3%, 0%, 23.1%)
CIE-LABlab(37.17, 42.82, -65.92)
CIE-LCHlch(37.17, 78.60, 303.01°)
OKLaboklab(47.65% 0.0381 -0.1897)
OKLCHoklch(47.65% 0.194 281.4)
XYZxyz(15.3022, 9.6302, 53.2663)
Luminance0.0963 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5142C4 #B5C442
analogous
#4274C4 #5142C4 #9242C4
triadic
#5142C4 #C45142 #42C451
tetradic
#5142C4 #C44274 #B5C442 #42C492
square
#5142C4 #C44274 #B5C442 #42C492
split-complementary
#5142C4 #C49242 #74C442
monochromatic
#2A216A #3C3099 #5142C4 #7C71D3 #A79FE1

Accessibility & contrast

On white

7.18
#5142C4 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.93
#5142C4 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5142C4
7.18:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5142C4#FFFFFF#000000##FFFFFF
##5142C41.007.182.937.18
#FFFFFF7.181.0021.001.00
#0000002.9321.001.0021.00
##FFFFFF7.181.0021.001.00

Color blindness preview

Protanopia (red-blind)
#005CC8
Deuteranopia (green-blind)
#0053C1
Tritanopia (blue-blind)
#01637D
Achromatopsia (no color)
#575757

Design tokens & code

CSS
--color: #5142c4;
/* rgb */ color: rgb(81, 66, 196);
/* oklch */ color: oklch(47.7% 0.194 281.4);
Tailwind
colors: {
  custom: {
    50: '#8e78d7',
    500: '#5142c4',
    950: '#000000',
  },
}
SCSS
$custom: #5142c4;
$custom-light: #8e78d7;
$custom-dark: #000000;
JSON
{
  "hex": "#5142c4",
  "rgb": {
    "r": 81,
    "g": 66,
    "b": 196
  },
  "hsl": {
    "h": 246.923,
    "s": 52.419,
    "l": 51.373
  },
  "oklch": {
    "l": 0.47651,
    "c": 0.19353,
    "h": 281.4
  },
  "luminance": 0.09631
}

Semantic roles & 50–950 ramp

primary
#5142C4
secondary
#C7CE94
accent
#DC4CCB
background
#F9F7FD
surface
#F2EDFA
border
#CCC8D3
text
#0D0914
muted
#7E7B83

Preview Lab

Preview with #5142C4

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

Preview Lab → · Contrast checker → · Palette generator →

#5142C4 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva