#5138BE#5138BE

#5138BE is a mid, vivid violet. Relative luminance 0.083; OKLCH L 45.6% C 0.198 H 283.9°. Best body text is #FFFFFF at 7.90:1 contrast (WCAG AA passes).

Color values

HEX#5138BE
RGBrgb(81, 56, 190)
HSLhsl(251, 54%, 48%)
HSVhsv(251, 71%, 75%)
CMYKcmyk(57.4%, 70.5%, 0%, 25.5%)
CIE-LABlab(34.59, 46.62, -66.63)
CIE-LCHlch(34.59, 81.32, 304.98°)
OKLaboklab(45.64% 0.0474 -0.1918)
OKLCHoklch(45.64% 0.198 283.9)
XYZxyz(14.0989, 8.2945, 49.5633)
Luminance0.0829 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5138BE #A5BE38
analogous
#3862BE #5138BE #9438BE
triadic
#5138BE #BE5138 #38BE51
tetradic
#5138BE #BE3862 #A5BE38 #38BE94
square
#5138BE #BE3862 #A5BE38 #38BE94
split-complementary
#5138BE #BE9438 #62BE38
monochromatic
#291C5F #3D2A8F #5138BE #7762D1 #A092DF

Accessibility & contrast

On white

7.90
#5138BE on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.66
#5138BE on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5138BE
7.90:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5138BE#FFFFFF#000000##FFFFFF
##5138BE1.007.902.667.90
#FFFFFF7.901.0021.001.00
#0000002.6621.001.0021.00
##FFFFFF7.901.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0055C2
Deuteranopia (green-blind)
#004DBB
Tritanopia (blue-blind)
#165C77
Achromatopsia (no color)
#515151

Design tokens & code

CSS
--color: #5138be;
/* rgb */ color: rgb(81, 56, 190);
/* oklch */ color: oklch(45.6% 0.198 283.9);
Tailwind
colors: {
  custom: {
    50: '#8d71d3',
    500: '#5138be',
    950: '#000000',
  },
}
SCSS
$custom: #5138be;
$custom-light: #8d71d3;
$custom-dark: #000000;
JSON
{
  "hex": "#5138be",
  "rgb": {
    "r": 81,
    "g": 56,
    "b": 190
  },
  "hsl": {
    "h": 251.194,
    "s": 54.472,
    "l": 48.235
  },
  "oklch": {
    "l": 0.45638,
    "c": 0.19758,
    "h": 283.9
  },
  "luminance": 0.08295
}

Semantic roles & 50–950 ramp

primary
#5138BE
secondary
#BDCA88
accent
#DE4AC2
background
#F9F6FD
surface
#F2ECFA
border
#CCC7D3
text
#0D0814
muted
#7E7B83

Preview Lab

Preview with #5138BE

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

Preview Lab → · Contrast checker → · Palette generator →

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