#5131C2#5131C2

#5131C2 is a mid, highly saturated violet. Relative luminance 0.078; OKLCH L 45.1% C 0.210 H 284.3°. Best body text is #FFFFFF at 8.18:1 contrast (WCAG AA passes).

Color values

HEX#5131C2
RGBrgb(81, 49, 194)
HSLhsl(253, 60%, 48%)
HSVhsv(253, 75%, 76%)
CMYKcmyk(58.2%, 74.7%, 0%, 23.9%)
CIE-LABlab(33.65, 51.48, -70.52)
CIE-LCHlch(33.65, 87.31, 306.13°)
OKLaboklab(45.08% 0.0518 -0.2032)
OKLCHoklch(45.08% 0.21 284.3)
XYZxyz(14.2263, 7.8401, 51.7921)
Luminance0.0784 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5131C2 #A2C231
analogous
#315AC2 #5131C2 #9931C2
triadic
#5131C2 #C25131 #31C251
tetradic
#5131C2 #C2315A #A2C231 #31C299
square
#5131C2 #C2315A #A2C231 #31C299
split-complementary
#5131C2 #C29931 #5AC231
monochromatic
#281860 #3D2591 #5131C2 #765BD6 #9F8CE2

Accessibility & contrast

On white

8.18
#5131C2 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.57
#5131C2 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5131C2
8.18:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5131C2#FFFFFF#000000##FFFFFF
##5131C21.008.182.578.18
#FFFFFF8.181.0021.001.00
#0000002.5721.001.0021.00
##FFFFFF8.181.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0053C6
Deuteranopia (green-blind)
#004ABF
Tritanopia (blue-blind)
#0E5A77
Achromatopsia (no color)
#4F4F4F

Design tokens & code

CSS
--color: #5131c2;
/* rgb */ color: rgb(81, 49, 194);
/* oklch */ color: oklch(45.1% 0.210 284.3);
Tailwind
colors: {
  custom: {
    50: '#8f6dd6',
    500: '#5131c2',
    950: '#000000',
  },
}
SCSS
$custom: #5131c2;
$custom-light: #8f6dd6;
$custom-dark: #000000;
JSON
{
  "hex": "#5131c2",
  "rgb": {
    "r": 81,
    "g": 49,
    "b": 194
  },
  "hsl": {
    "h": 253.241,
    "s": 59.671,
    "l": 47.647
  },
  "oklch": {
    "l": 0.45083,
    "c": 0.20968,
    "h": 284.3
  },
  "luminance": 0.07841
}

Semantic roles & 50–950 ramp

primary
#5131C2
secondary
#BCCC83
accent
#E345C0
background
#F9F6FD
surface
#F2ECFA
border
#CCC7D3
text
#0E0714
muted
#7E7A83

Preview Lab

Preview with #5131C2

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

Preview Lab → · Contrast checker → · Palette generator →

#5131C2 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva