#5126A4#5126A4

#5126A4 is a dark, vivid violet. Relative luminance 0.058; OKLCH L 40.9% C 0.186 H 291.4°. Best body text is #FFFFFF at 9.71:1 contrast (WCAG AA passes).

Color values

HEX#5126A4
RGBrgb(81, 38, 164)
HSLhsl(260, 62%, 40%)
HSVhsv(260, 77%, 64%)
CMYKcmyk(50.6%, 76.8%, 0%, 35.7%)
CIE-LABlab(28.94, 48.35, -60.38)
CIE-LCHlch(28.94, 77.36, 308.68°)
OKLaboklab(40.92% 0.0681 -0.1734)
OKLCHoklch(40.92% 0.186 291.4)
XYZxyz(10.7854, 5.8155, 35.6690)
Luminance0.0582 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5126A4 #79A426
analogous
#263AA4 #5126A4 #9026A4
triadic
#5126A4 #A45126 #26A451
tetradic
#5126A4 #A4263A #79A426 #26A490
square
#5126A4 #A4263A #79A426 #26A490
split-complementary
#5126A4 #A49026 #3AA426
monochromatic
#200F41 #381A72 #5126A4 #6B37D1 #9068DC

Accessibility & contrast

On white

9.71
#5126A4 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.16
#5126A4 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5126A4
9.71:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5126A4#FFFFFF#000000##FFFFFF
##5126A41.009.712.169.71
#FFFFFF9.711.0021.001.00
#0000002.1621.001.0021.00
##FFFFFF9.711.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0046A8
Deuteranopia (green-blind)
#0042A2
Tritanopia (blue-blind)
#354964
Achromatopsia (no color)
#444444

Design tokens & code

CSS
--color: #5126a4;
/* rgb */ color: rgb(81, 38, 164);
/* oklch */ color: oklch(40.9% 0.186 291.4);
Tailwind
colors: {
  custom: {
    50: '#8b65c0',
    500: '#5126a4',
    950: '#000000',
  },
}
SCSS
$custom: #5126a4;
$custom-light: #8b65c0;
$custom-dark: #000000;
JSON
{
  "hex": "#5126a4",
  "rgb": {
    "r": 81,
    "g": 38,
    "b": 164
  },
  "hsl": {
    "h": 260.476,
    "s": 62.376,
    "l": 39.608
  },
  "oklch": {
    "l": 0.40922,
    "c": 0.18629,
    "h": 291.4
  },
  "luminance": 0.05816
}

Semantic roles & 50–950 ramp

primary
#5126A4
secondary
#A2C264
accent
#E542AE
background
#F9F6FB
surface
#F1EBF7
border
#CBC6D0
text
#0D0612
muted
#7E7A81

Preview Lab

Preview with #5126A4

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

Preview Lab → · Contrast checker → · Palette generator →

#5126A4 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva