#542FA9#542FA9

#542FA9 is a dark, vivid violet. Relative luminance 0.068; OKLCH L 42.8% C 0.182 H 290.4°. Best body text is #FFFFFF at 8.91:1 contrast (WCAG AA passes).

Color values

HEX#542FA9
RGBrgb(84, 47, 169)
HSLhsl(258, 56%, 42%)
HSVhsv(258, 72%, 66%)
CMYKcmyk(50.3%, 72.2%, 0%, 33.7%)
CIE-LABlab(31.31, 45.76, -59.51)
CIE-LCHlch(31.31, 75.07, 307.55°)
OKLaboklab(42.8% 0.0637 -0.1708)
OKLCHoklch(42.8% 0.182 290.4)
XYZxyz(11.8321, 6.7819, 38.2140)
Luminance0.0678 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#542FA9 #84A92F
analogous
#2F47A9 #542FA9 #912FA9
triadic
#542FA9 #A9542F #2FA954
tetradic
#542FA9 #A92F47 #84A92F #2FA991
square
#542FA9 #A92F47 #84A92F #2FA991
split-complementary
#542FA9 #A9912F #47A92F
monochromatic
#241449 #3C2279 #542FA9 #7149CC #9679DA

Accessibility & contrast

On white

8.91
#542FA9 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.36
#542FA9 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #542FA9
8.91:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##542FA9#FFFFFF#000000##FFFFFF
##542FA91.008.912.368.91
#FFFFFF8.911.0021.001.00
#0000002.3621.001.0021.00
##FFFFFF8.911.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004CAD
Deuteranopia (green-blind)
#0047A7
Tritanopia (blue-blind)
#374F69
Achromatopsia (no color)
#4A4A4A

Design tokens & code

CSS
--color: #542fa9;
/* rgb */ color: rgb(84, 47, 169);
/* oklch */ color: oklch(42.8% 0.182 290.4);
Tailwind
colors: {
  custom: {
    50: '#8c6bc4',
    500: '#542fa9',
    950: '#000000',
  },
}
SCSS
$custom: #542fa9;
$custom-light: #8c6bc4;
$custom-dark: #000000;
JSON
{
  "hex": "#542fa9",
  "rgb": {
    "r": 84,
    "g": 47,
    "b": 169
  },
  "hsl": {
    "h": 258.197,
    "s": 56.481,
    "l": 42.353
  },
  "oklch": {
    "l": 0.42804,
    "c": 0.1823,
    "h": 290.4
  },
  "luminance": 0.06782
}

Semantic roles & 50–950 ramp

primary
#542FA9
secondary
#AAC272
accent
#E048B2
background
#F9F6FC
surface
#F1EBF8
border
#CBC6D1
text
#0D0713
muted
#7E7A82

Preview Lab

Preview with #542FA9

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

Preview Lab → · Contrast checker → · Palette generator →

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