#5125B1#5125B1

#5125B1 is a dark, highly saturated violet. Relative luminance 0.062; OKLCH L 42.1% C 0.202 H 288.8°. Best body text is #FFFFFF at 9.34:1 contrast (WCAG AA passes).

Color values

HEX#5125B1
RGBrgb(81, 37, 177)
HSLhsl(259, 65%, 42%)
HSVhsv(259, 79%, 69%)
CMYKcmyk(54.2%, 79.1%, 0%, 30.6%)
CIE-LABlab(30.03, 52.37, -66.42)
CIE-LCHlch(30.03, 84.58, 308.25°)
OKLaboklab(42.05% 0.065 -0.1911)
OKLCHoklch(42.05% 0.202 288.8)
XYZxyz(11.9884, 6.2462, 42.1604)
Luminance0.0625 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5125B1 #85B125
analogous
#253FB1 #5125B1 #9725B1
triadic
#5125B1 #B15125 #25B151
tetradic
#5125B1 #B1253F #85B125 #25B197
square
#5125B1 #B1253F #85B125 #25B197
split-complementary
#5125B1 #B19725 #3FB125
monochromatic
#23104C #3A1A7E #5125B1 #6D3DD6 #936FE1

Accessibility & contrast

On white

9.34
#5125B1 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.25
#5125B1 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5125B1
9.34:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5125B1#FFFFFF#000000##FFFFFF
##5125B11.009.342.259.34
#FFFFFF9.341.0021.001.00
#0000002.2521.001.0021.00
##FFFFFF9.341.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004AB5
Deuteranopia (green-blind)
#0043AE
Tritanopia (blue-blind)
#2A4E6B
Achromatopsia (no color)
#474747

Design tokens & code

CSS
--color: #5125b1;
/* rgb */ color: rgb(81, 37, 177);
/* oklch */ color: oklch(42.1% 0.202 288.8);
Tailwind
colors: {
  custom: {
    50: '#8d66ca',
    500: '#5125b1',
    950: '#000000',
  },
}
SCSS
$custom: #5125b1;
$custom-light: #8d66ca;
$custom-dark: #000000;
JSON
{
  "hex": "#5125b1",
  "rgb": {
    "r": 81,
    "g": 37,
    "b": 177
  },
  "hsl": {
    "h": 258.857,
    "s": 65.421,
    "l": 41.961
  },
  "oklch": {
    "l": 0.42054,
    "c": 0.20181,
    "h": 288.8
  },
  "luminance": 0.06247
}

Semantic roles & 50–950 ramp

primary
#5125B1
secondary
#AAC86A
accent
#E83FB3
background
#F9F6FC
surface
#F2EBF8
border
#CCC6D1
text
#0D0613
muted
#7E7A82

Preview Lab

Preview with #5125B1

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

Preview Lab → · Contrast checker → · Palette generator →

#5125B1 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva