#542AC7#542AC7

#542AC7 is a mid, highly saturated violet. Relative luminance 0.077; OKLCH L 45.0% C 0.221 H 285.6°. Best body text is #FFFFFF at 8.29:1 contrast (WCAG AA passes).

Color values

HEX#542AC7
RGBrgb(84, 42, 199)
HSLhsl(256, 65%, 47%)
HSVhsv(256, 79%, 78%)
CMYKcmyk(57.8%, 78.9%, 0%, 22%)
CIE-LABlab(33.27, 56.55, -74.06)
CIE-LCHlch(33.27, 93.18, 307.37°)
OKLaboklab(45.04% 0.0595 -0.2133)
OKLCHoklch(45.04% 0.221 285.6)
XYZxyz(14.7898, 7.6634, 54.7216)
Luminance0.0766 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#542AC7 #9DC72A
analogous
#2A4FC7 #542AC7 #A32AC7
triadic
#542AC7 #C7542A #2AC754
tetradic
#542AC7 #C72A4F #9DC72A #2AC7A3
square
#542AC7 #C72A4F #9DC72A #2AC7A3
split-complementary
#542AC7 #C7A32A #4FC72A
monochromatic
#291562 #3F1F94 #542AC7 #7853DB #9F86E5

Accessibility & contrast

On white

8.29
#542AC7 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.53
#542AC7 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #542AC7
8.29:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##542AC7#FFFFFF#000000##FFFFFF
##542AC71.008.292.538.29
#FFFFFF8.291.0021.001.00
#0000002.5321.001.0021.00
##FFFFFF8.291.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0052CB
Deuteranopia (green-blind)
#0049C4
Tritanopia (blue-blind)
#155979
Achromatopsia (no color)
#4E4E4E

Design tokens & code

CSS
--color: #542ac7;
/* rgb */ color: rgb(84, 42, 199);
/* oklch */ color: oklch(45.0% 0.221 285.6);
Tailwind
colors: {
  custom: {
    50: '#916ad9',
    500: '#542ac7',
    950: '#000000',
  },
}
SCSS
$custom: #542ac7;
$custom-light: #916ad9;
$custom-dark: #000000;
JSON
{
  "hex": "#542ac7",
  "rgb": {
    "r": 84,
    "g": 42,
    "b": 199
  },
  "hsl": {
    "h": 256.051,
    "s": 65.145,
    "l": 47.255
  },
  "oklch": {
    "l": 0.45036,
    "c": 0.22149,
    "h": 285.6
  },
  "luminance": 0.07664
}

Semantic roles & 50–950 ramp

primary
#542AC7
secondary
#B9CF7E
accent
#E840BB
background
#F9F6FD
surface
#F2EBFB
border
#CCC6D4
text
#0E0715
muted
#7E7A83

Preview Lab

Preview with #542AC7

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

Preview Lab → · Contrast checker → · Palette generator →

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