#5126AF#5126AF

#5126AF is a dark, vivid violet. Relative luminance 0.062; OKLCH L 42.0% C 0.199 H 289.1°. Best body text is #FFFFFF at 9.35:1 contrast (WCAG AA passes).

Color values

HEX#5126AF
RGBrgb(81, 38, 175)
HSLhsl(259, 64%, 42%)
HSVhsv(259, 78%, 69%)
CMYKcmyk(53.7%, 78.3%, 0%, 31.4%)
CIE-LABlab(29.99, 51.37, -65.29)
CIE-LCHlch(29.99, 83.08, 308.20°)
OKLaboklab(41.97% 0.0649 -0.1878)
OKLCHoklch(41.97% 0.199 289.1)
XYZxyz(11.8221, 6.2301, 41.1287)
Luminance0.0623 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5126AF #84AF26
analogous
#2640AF #5126AF #9626AF
triadic
#5126AF #AF5126 #26AF51
tetradic
#5126AF #AF2640 #84AF26 #26AF96
square
#5126AF #AF2640 #84AF26 #26AF96
split-complementary
#5126AF #AF9626 #40AF26
monochromatic
#22104A #3A1B7D #5126AF #6D3DD5 #9370E0

Accessibility & contrast

On white

9.35
#5126AF on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.25
#5126AF on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5126AF
9.35:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5126AF#FFFFFF#000000##FFFFFF
##5126AF1.009.352.259.35
#FFFFFF9.351.0021.001.00
#0000002.2521.001.0021.00
##FFFFFF9.351.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0049B3
Deuteranopia (green-blind)
#0043AD
Tritanopia (blue-blind)
#2C4D6A
Achromatopsia (no color)
#474747

Design tokens & code

CSS
--color: #5126af;
/* rgb */ color: rgb(81, 38, 175);
/* oklch */ color: oklch(42.0% 0.199 289.1);
Tailwind
colors: {
  custom: {
    50: '#8c66c8',
    500: '#5126af',
    950: '#000000',
  },
}
SCSS
$custom: #5126af;
$custom-light: #8c66c8;
$custom-dark: #000000;
JSON
{
  "hex": "#5126af",
  "rgb": {
    "r": 81,
    "g": 38,
    "b": 175
  },
  "hsl": {
    "h": 258.832,
    "s": 64.319,
    "l": 41.765
  },
  "oklch": {
    "l": 0.41968,
    "c": 0.19866,
    "h": 289.1
  },
  "luminance": 0.06231
}

Semantic roles & 50–950 ramp

primary
#5126AF
secondary
#AAC76A
accent
#E740B3
background
#F9F6FC
surface
#F1EBF8
border
#CBC6D1
text
#0D0613
muted
#7E7A82

Preview Lab

Preview with #5126AF

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

Preview Lab → · Contrast checker → · Palette generator →

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