#5126A5#5126A5

#5126A5 is a dark, vivid violet. Relative luminance 0.059; OKLCH L 41.0% C 0.187 H 291.2°. Best body text is #FFFFFF at 9.68:1 contrast (WCAG AA passes).

Color values

HEX#5126A5
RGBrgb(81, 38, 165)
HSLhsl(260, 63%, 40%)
HSVhsv(260, 77%, 65%)
CMYKcmyk(50.9%, 77%, 0%, 35.3%)
CIE-LABlab(29.04, 48.63, -60.84)
CIE-LCHlch(29.04, 77.88, 308.63°)
OKLaboklab(41.02% 0.0678 -0.1747)
OKLCHoklch(41.02% 0.187 291.2)
XYZxyz(10.8760, 5.8517, 36.1465)
Luminance0.0585 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5126A5 #7AA526
analogous
#263AA5 #5126A5 #9126A5
triadic
#5126A5 #A55126 #26A551
tetradic
#5126A5 #A5263A #7AA526 #26A591
square
#5126A5 #A5263A #7AA526 #26A591
split-complementary
#5126A5 #A59126 #3AA526
monochromatic
#200F42 #391B73 #5126A5 #6B37D1 #9069DC

Accessibility & contrast

On white

9.68
#5126A5 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.17
#5126A5 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5126A5
9.68:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5126A5#FFFFFF#000000##FFFFFF
##5126A51.009.682.179.68
#FFFFFF9.681.0021.001.00
#0000002.1721.001.0021.00
##FFFFFF9.681.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0046A9
Deuteranopia (green-blind)
#0042A3
Tritanopia (blue-blind)
#344964
Achromatopsia (no color)
#444444

Design tokens & code

CSS
--color: #5126a5;
/* rgb */ color: rgb(81, 38, 165);
/* oklch */ color: oklch(41.0% 0.187 291.2);
Tailwind
colors: {
  custom: {
    50: '#8b65c1',
    500: '#5126a5',
    950: '#000000',
  },
}
SCSS
$custom: #5126a5;
$custom-light: #8b65c1;
$custom-dark: #000000;
JSON
{
  "hex": "#5126a5",
  "rgb": {
    "r": 81,
    "g": 38,
    "b": 165
  },
  "hsl": {
    "h": 260.315,
    "s": 62.562,
    "l": 39.804
  },
  "oklch": {
    "l": 0.41016,
    "c": 0.18743,
    "h": 291.2
  },
  "luminance": 0.05852
}

Semantic roles & 50–950 ramp

primary
#5126A5
secondary
#A3C364
accent
#E642AE
background
#F9F6FC
surface
#F1EBF8
border
#CBC6D1
text
#0D0612
muted
#7E7A81

Preview Lab

Preview with #5126A5

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

Preview Lab → · Contrast checker → · Palette generator →

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