#8A42B2#8A42B2

#8A42B2 is a mid, vivid violet. Relative luminance 0.125; OKLCH L 52.2% C 0.177 H 311.4°. Best body text is #FFFFFF at 6.00:1 contrast (WCAG AA passes).

Color values

HEX#8A42B2
RGBrgb(138, 66, 178)
HSLhsl(279, 46%, 48%)
HSVhsv(279, 63%, 70%)
CMYKcmyk(22.5%, 62.9%, 0%, 30.2%)
CIE-LABlab(42.02, 49.58, -47.20)
CIE-LCHlch(42.02, 68.46, 316.41°)
OKLaboklab(52.16% 0.1172 -0.1329)
OKLCHoklch(52.16% 0.177 311.4)
XYZxyz(20.4638, 12.5145, 43.4484)
Luminance0.1251 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#8A42B2 #6AB242
analogous
#5242B2 #8A42B2 #B242A2
triadic
#8A42B2 #B28A42 #42B28A
tetradic
#8A42B2 #B25242 #6AB242 #42A2B2
square
#8A42B2 #B25242 #6AB242 #42A2B2
split-complementary
#8A42B2 #A2B242 #42B252
monochromatic
#452159 #673185 #8A42B2 #A66AC8 #C196D8

Accessibility & contrast

On white

6.00
#8A42B2 on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

3.50
#8A42B2 on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #8A42B2
6.00:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##8A42B2#FFFFFF#000000##FFFFFF
##8A42B21.006.003.506.00
#FFFFFF6.001.0021.001.00
#0000003.5021.001.0021.00
##FFFFFF6.001.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0F60B5
Deuteranopia (green-blind)
#3765AF
Tritanopia (blue-blind)
#855874
Achromatopsia (no color)
#636363

Design tokens & code

CSS
--color: #8a42b2;
/* rgb */ color: rgb(138, 66, 178);
/* oklch */ color: oklch(52.2% 0.177 311.4);
Tailwind
colors: {
  custom: {
    50: '#af7bca',
    500: '#8a42b2',
    950: '#000000',
  },
}
SCSS
$custom: #8a42b2;
$custom-light: #af7bca;
$custom-dark: #000000;
JSON
{
  "hex": "#8a42b2",
  "rgb": {
    "r": 138,
    "g": 66,
    "b": 178
  },
  "hsl": {
    "h": 278.571,
    "s": 45.902,
    "l": 47.843
  },
  "oklch": {
    "l": 0.52159,
    "c": 0.17718,
    "h": 311.4
  },
  "luminance": 0.12514
}

Semantic roles & 50–950 ramp

primary
#8A42B2
secondary
#A0C48C
accent
#D65281
background
#FBF7FC
surface
#F6EEF8
border
#D0C9D1
text
#110A13
muted
#807C82

Preview Lab

Preview with #8A42B2

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

Preview Lab → · Contrast checker → · Palette generator →

#8A42B2 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva