#5A2FA5#5A2FA5

#5A2FA5 is a dark, vivid violet. Relative luminance 0.069; OKLCH L 43.1% C 0.178 H 294.4°. Best body text is #FFFFFF at 8.81:1 contrast (WCAG AA passes).

Color values

HEX#5A2FA5
RGBrgb(90, 47, 165)
HSLhsl(262, 56%, 42%)
HSVhsv(262, 72%, 65%)
CMYKcmyk(45.5%, 71.5%, 0%, 35.3%)
CIE-LABlab(31.63, 45.68, -56.55)
CIE-LCHlch(31.63, 72.70, 308.93°)
OKLaboklab(43.08% 0.0734 -0.1619)
OKLCHoklch(43.08% 0.178 294.4)
XYZxyz(12.0227, 6.9230, 36.2928)
Luminance0.0692 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5A2FA5 #7AA52F
analogous
#2F3FA5 #5A2FA5 #952FA5
triadic
#5A2FA5 #A55A2F #2FA55A
tetradic
#5A2FA5 #A52F3F #7AA52F #2FA595
square
#5A2FA5 #A52F3F #7AA52F #2FA595
split-complementary
#5A2FA5 #A5952F #3FA52F
monochromatic
#261446 #402175 #5A2FA5 #7747CB #9A76D8

Accessibility & contrast

On white

8.81
#5A2FA5 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.38
#5A2FA5 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #5A2FA5
8.81:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5A2FA5#FFFFFF#000000##FFFFFF
##5A2FA51.008.812.388.81
#FFFFFF8.811.0021.001.00
#0000002.3821.001.0021.00
##FFFFFF8.811.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004CA8
Deuteranopia (green-blind)
#0048A3
Tritanopia (blue-blind)
#454D67
Achromatopsia (no color)
#4A4A4A

Design tokens & code

CSS
--color: #5a2fa5;
/* rgb */ color: rgb(90, 47, 165);
/* oklch */ color: oklch(43.1% 0.178 294.4);
Tailwind
colors: {
  custom: {
    50: '#8f6bc1',
    500: '#5a2fa5',
    950: '#000000',
  },
}
SCSS
$custom: #5a2fa5;
$custom-light: #8f6bc1;
$custom-dark: #000000;
JSON
{
  "hex": "#5a2fa5",
  "rgb": {
    "r": 90,
    "g": 47,
    "b": 165
  },
  "hsl": {
    "h": 261.864,
    "s": 55.66,
    "l": 41.569
  },
  "oklch": {
    "l": 0.43083,
    "c": 0.17775,
    "h": 294.4
  },
  "luminance": 0.06923
}

Semantic roles & 50–950 ramp

primary
#5A2FA5
secondary
#A3C070
accent
#DF49A8
background
#F9F6FC
surface
#F2EBF8
border
#CCC6D1
text
#0D0712
muted
#7E7A81

Preview Lab

Preview with #5A2FA5

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

Preview Lab → · Contrast checker → · Palette generator →

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