#5A2FA8#5A2FA8

#5A2FA8 is a dark, vivid violet. Relative luminance 0.070; OKLCH L 43.3% C 0.181 H 293.7°. Best body text is #FFFFFF at 8.73:1 contrast (WCAG AA passes).

Color values

HEX#5A2FA8
RGBrgb(90, 47, 168)
HSLhsl(261, 56%, 42%)
HSVhsv(261, 72%, 66%)
CMYKcmyk(46.4%, 72%, 0%, 34.1%)
CIE-LABlab(31.88, 46.51, -57.94)
CIE-LCHlch(31.88, 74.30, 308.75°)
OKLaboklab(43.34% 0.0728 -0.166)
OKLCHoklch(43.34% 0.181 293.7)
XYZxyz(12.2989, 7.0335, 37.7478)
Luminance0.0703 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5A2FA8 #7DA82F
analogous
#2F41A8 #5A2FA8 #962FA8
triadic
#5A2FA8 #A85A2F #2FA85A
tetradic
#5A2FA8 #A82F41 #7DA82F #2FA896
square
#5A2FA8 #A82F41 #7DA82F #2FA896
split-complementary
#5A2FA8 #A8962F #41A82F
monochromatic
#271448 #402278 #5A2FA8 #7748CC #9B78D9

Accessibility & contrast

On white

8.73
#5A2FA8 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.41
#5A2FA8 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5A2FA8
8.73:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5A2FA8#FFFFFF#000000##FFFFFF
##5A2FA81.008.732.418.73
#FFFFFF8.731.0021.001.00
#0000002.4121.001.0021.00
##FFFFFF8.731.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004CAC
Deuteranopia (green-blind)
#0049A6
Tritanopia (blue-blind)
#434E68
Achromatopsia (no color)
#4B4B4B

Design tokens & code

CSS
--color: #5a2fa8;
/* rgb */ color: rgb(90, 47, 168);
/* oklch */ color: oklch(43.3% 0.181 293.7);
Tailwind
colors: {
  custom: {
    50: '#906bc3',
    500: '#5a2fa8',
    950: '#000000',
  },
}
SCSS
$custom: #5a2fa8;
$custom-light: #906bc3;
$custom-dark: #000000;
JSON
{
  "hex": "#5a2fa8",
  "rgb": {
    "r": 90,
    "g": 47,
    "b": 168
  },
  "hsl": {
    "h": 261.322,
    "s": 56.279,
    "l": 42.157
  },
  "oklch": {
    "l": 0.43341,
    "c": 0.18124,
    "h": 293.7
  },
  "luminance": 0.07034
}

Semantic roles & 50–950 ramp

primary
#5A2FA8
secondary
#A5C171
accent
#E048AA
background
#F9F6FC
surface
#F2EBF8
border
#CCC6D1
text
#0D0713
muted
#7E7A82

Preview Lab

Preview with #5A2FA8

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

Preview Lab → · Contrast checker → · Palette generator →

#5A2FA8 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva