#42147E#42147E

#42147E is a dark, vivid violet. Relative luminance 0.032; OKLCH L 33.6% C 0.161 H 295.9°. Best body text is #FFFFFF at 12.86:1 contrast (WCAG AA passes).

Color values

HEX#42147E
RGBrgb(66, 20, 126)
HSLhsl(266, 73%, 29%)
HSVhsv(266, 84%, 49%)
CMYKcmyk(47.6%, 84.1%, 0%, 50.6%)
CIE-LABlab(20.69, 43.78, -50.46)
CIE-LCHlch(20.69, 66.81, 310.95°)
OKLaboklab(33.65% 0.0702 -0.1447)
OKLCHoklch(33.65% 0.161 295.9)
XYZxyz(6.2618, 3.1648, 20.0156)
Luminance0.0316 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#42147E #507E14
analogous
#141B7E #42147E #77147E
triadic
#42147E #7E4214 #147E42
tetradic
#42147E #7E141B #507E14 #147E77
square
#42147E #7E141B #507E14 #147E77
split-complementary
#42147E #7E7714 #1B7E14
monochromatic
#0E041A #260C49 #42147E #5E1CB3 #7B2EDE

Accessibility & contrast

On white

12.86
#42147E on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.63
#42147E on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #42147E
12.86:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##42147E#FFFFFF#000000##FFFFFF
##42147E1.0012.861.6312.86
#FFFFFF12.861.0021.001.00
#0000001.6321.001.0021.00
##FFFFFF12.861.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003281
Deuteranopia (green-blind)
#00307C
Tritanopia (blue-blind)
#31334A
Achromatopsia (no color)
#323232

Design tokens & code

CSS
--color: #42147e;
/* rgb */ color: rgb(66, 20, 126);
/* oklch */ color: oklch(33.6% 0.161 295.9);
Tailwind
colors: {
  custom: {
    50: '#7e59a4',
    500: '#42147e',
    950: '#000000',
  },
}
SCSS
$custom: #42147e;
$custom-light: #7e59a4;
$custom-dark: #000000;
JSON
{
  "hex": "#42147e",
  "rgb": {
    "r": 66,
    "g": 20,
    "b": 126
  },
  "hsl": {
    "h": 266.038,
    "s": 72.603,
    "l": 28.627
  },
  "oklch": {
    "l": 0.33646,
    "c": 0.16082,
    "h": 295.9
  },
  "luminance": 0.03165
}

Semantic roles & 50–950 ramp

primary
#42147E
secondary
#7FB33A
accent
#EF38A0
background
#F8F5FA
surface
#EFE9F4
border
#CAC5CE
text
#0B040F
muted
#7C797F

Preview Lab

Preview with #42147E

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

Preview Lab → · Contrast checker → · Palette generator →

#42147E Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva