#542FA6#542FA6

#542FA6 is a dark, vivid violet. Relative luminance 0.067; OKLCH L 42.5% C 0.179 H 291.1°. Best body text is #FFFFFF at 9.00:1 contrast (WCAG AA passes).

Color values

HEX#542FA6
RGBrgb(84, 47, 166)
HSLhsl(259, 56%, 42%)
HSVhsv(259, 72%, 65%)
CMYKcmyk(49.4%, 71.7%, 0%, 34.9%)
CIE-LABlab(31.04, 44.90, -58.14)
CIE-LCHlch(31.04, 73.46, 307.68°)
OKLaboklab(42.54% 0.0643 -0.1668)
OKLCHoklch(42.54% 0.179 291.1)
XYZxyz(11.5537, 6.6706, 36.7478)
Luminance0.0667 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#542FA6 #81A62F
analogous
#2F46A6 #542FA6 #902FA6
triadic
#542FA6 #A6542F #2FA654
tetradic
#542FA6 #A62F46 #81A62F #2FA690
square
#542FA6 #A62F46 #81A62F #2FA690
split-complementary
#542FA6 #A6902F #46A62F
monochromatic
#241447 #3C2176 #542FA6 #7047CB #9577D8

Accessibility & contrast

On white

9.00
#542FA6 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.33
#542FA6 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #542FA6
9.00:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##542FA6#FFFFFF#000000##FFFFFF
##542FA61.009.002.339.00
#FFFFFF9.001.0021.001.00
#0000002.3321.001.0021.00
##FFFFFF9.001.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004BAA
Deuteranopia (green-blind)
#0046A4
Tritanopia (blue-blind)
#394E67
Achromatopsia (no color)
#494949

Design tokens & code

CSS
--color: #542fa6;
/* rgb */ color: rgb(84, 47, 166);
/* oklch */ color: oklch(42.5% 0.179 291.1);
Tailwind
colors: {
  custom: {
    50: '#8c6bc1',
    500: '#542fa6',
    950: '#000000',
  },
}
SCSS
$custom: #542fa6;
$custom-light: #8c6bc1;
$custom-dark: #000000;
JSON
{
  "hex": "#542fa6",
  "rgb": {
    "r": 84,
    "g": 47,
    "b": 166
  },
  "hsl": {
    "h": 258.655,
    "s": 55.869,
    "l": 41.765
  },
  "oklch": {
    "l": 0.42538,
    "c": 0.17873,
    "h": 291.1
  },
  "luminance": 0.06671
}

Semantic roles & 50–950 ramp

primary
#542FA6
secondary
#A8C170
accent
#DF49B0
background
#F9F6FC
surface
#F1EBF8
border
#CBC6D1
text
#0D0712
muted
#7E7A81

Preview Lab

Preview with #542FA6

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

Preview Lab → · Contrast checker → · Palette generator →

#542FA6 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva