#5A42CF#5A42CF

#5A42CF is a mid, highly saturated violet. Relative luminance 0.106; OKLCH L 49.3% C 0.206 H 283.7°. Best body text is #FFFFFF at 6.74:1 contrast (WCAG AA passes).

Color values

HEX#5A42CF
RGBrgb(90, 66, 207)
HSLhsl(250, 59%, 54%)
HSVhsv(250, 68%, 81%)
CMYKcmyk(56.5%, 68.1%, 0%, 18.8%)
CIE-LABlab(38.85, 47.60, -69.52)
CIE-LCHlch(38.85, 84.25, 304.40°)
OKLaboklab(49.34% 0.0486 -0.2)
OKLCHoklch(49.34% 0.206 283.7)
XYZxyz(17.4237, 10.5740, 60.1422)
Luminance0.1057 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#5A42CF #B7CF42
analogous
#4270CF #5A42CF #A042CF
triadic
#5A42CF #CF5A42 #42CF5A
tetradic
#5A42CF #CF4270 #B7CF42 #42CFA0
square
#5A42CF #CF4270 #B7CF42 #42CFA0
split-complementary
#5A42CF #CFA042 #70CF42
monochromatic
#2E1F78 #402BA9 #5A42CF #8573DB #AFA4E8

Accessibility & contrast

On white

6.74
#5A42CF on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

3.12
#5A42CF on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #5A42CF
6.74:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##5A42CF#FFFFFF#000000##FFFFFF
##5A42CF1.006.743.126.74
#FFFFFF6.741.0021.001.00
#0000003.1221.001.0021.00
##FFFFFF6.741.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0060D3
Deuteranopia (green-blind)
#0057CC
Tritanopia (blue-blind)
#1E6783
Achromatopsia (no color)
#5B5B5B

Design tokens & code

CSS
--color: #5a42cf;
/* rgb */ color: rgb(90, 66, 207);
/* oklch */ color: oklch(49.3% 0.206 283.7);
Tailwind
colors: {
  custom: {
    50: '#9478df',
    500: '#5a42cf',
    950: '#000000',
  },
}
SCSS
$custom: #5a42cf;
$custom-light: #9478df;
$custom-dark: #000000;
JSON
{
  "hex": "#5a42cf",
  "rgb": {
    "r": 90,
    "g": 66,
    "b": 207
  },
  "hsl": {
    "h": 250.213,
    "s": 59.494,
    "l": 53.529
  },
  "oklch": {
    "l": 0.49337,
    "c": 0.20586,
    "h": 283.7
  },
  "luminance": 0.10575
}

Semantic roles & 50–950 ramp

primary
#5A42CF
secondary
#CAD598
accent
#E345C8
background
#F9F7FD
surface
#F2EDFB
border
#CCC8D4
text
#0E0915
muted
#7E7B83

Preview Lab

Preview with #5A42CF

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

Preview Lab → · Contrast checker → · Palette generator →

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