#5127B4#5127B4

#5127B4 is a dark, highly saturated violet. Relative luminance 0.065; OKLCH L 42.6% C 0.203 H 288.0°. Best body text is #FFFFFF at 9.13:1 contrast (WCAG AA passes).

Color values

HEX#5127B4
RGBrgb(81, 39, 180)
HSLhsl(258, 64%, 43%)
HSVhsv(258, 78%, 71%)
CMYKcmyk(55%, 78.3%, 0%, 29.4%)
CIE-LABlab(30.63, 52.29, -67.22)
CIE-LCHlch(30.63, 85.16, 307.88°)
OKLaboklab(42.56% 0.0627 -0.1934)
OKLCHoklch(42.56% 0.203 288)
XYZxyz(12.3546, 6.4950, 43.7738)
Luminance0.0650 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5127B4 #8AB427
analogous
#2744B4 #5127B4 #9727B4
triadic
#5127B4 #B45127 #27B451
tetradic
#5127B4 #B42744 #8AB427 #27B497
square
#5127B4 #B42744 #8AB427 #27B497
split-complementary
#5127B4 #B49727 #44B427
monochromatic
#24114F #3A1C82 #5127B4 #6E42D6 #9574E1

Accessibility & contrast

On white

9.13
#5127B4 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.30
#5127B4 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5127B4
9.13:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5127B4#FFFFFF#000000##FFFFFF
##5127B41.009.132.309.13
#FFFFFF9.131.0021.001.00
#0000002.3021.001.0021.00
##FFFFFF9.131.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004BB8
Deuteranopia (green-blind)
#0044B1
Tritanopia (blue-blind)
#27506D
Achromatopsia (no color)
#484848

Design tokens & code

CSS
--color: #5127b4;
/* rgb */ color: rgb(81, 39, 180);
/* oklch */ color: oklch(42.6% 0.203 288.0);
Tailwind
colors: {
  custom: {
    50: '#8d67cc',
    500: '#5127b4',
    950: '#000000',
  },
}
SCSS
$custom: #5127b4;
$custom-light: #8d67cc;
$custom-dark: #000000;
JSON
{
  "hex": "#5127b4",
  "rgb": {
    "r": 81,
    "g": 39,
    "b": 180
  },
  "hsl": {
    "h": 257.872,
    "s": 64.384,
    "l": 42.941
  },
  "oklch": {
    "l": 0.42563,
    "c": 0.20332,
    "h": 288
  },
  "luminance": 0.06496
}

Semantic roles & 50–950 ramp

primary
#5127B4
secondary
#AEC86F
accent
#E740B6
background
#F9F6FC
surface
#F2EBF9
border
#CCC6D2
text
#0D0613
muted
#7E7A82

Preview Lab

Preview with #5127B4

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

Preview Lab → · Contrast checker → · Palette generator →

#5127B4 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva