#42127F#42127F

#42127F is a dark, vivid violet. Relative luminance 0.031; OKLCH L 33.6% C 0.164 H 295.8°. Best body text is #FFFFFF at 12.93:1 contrast (WCAG AA passes).

Color values

HEX#42127F
RGBrgb(66, 18, 127)
HSLhsl(266, 75%, 28%)
HSVhsv(266, 86%, 50%)
CMYKcmyk(48%, 85.8%, 0%, 50.2%)
CIE-LABlab(20.53, 44.82, -51.36)
CIE-LCHlch(20.53, 68.16, 311.11°)
OKLaboklab(33.56% 0.0712 -0.1473)
OKLCHoklch(33.56% 0.164 295.8)
XYZxyz(6.2928, 3.1230, 20.3458)
Luminance0.0312 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#42127F #4F7F12
analogous
#12187F #42127F #78127F
triadic
#42127F #7F4212 #127F42
tetradic
#42127F #7F1218 #4F7F12 #127F78
square
#42127F #7F1218 #4F7F12 #127F78
split-complementary
#42127F #7F7812 #187F12
monochromatic
#0E041B #260A49 #42127F #5E1AB5 #7B2BE1

Accessibility & contrast

On white

12.93
#42127F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.62
#42127F on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #42127F
12.93:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##42127F#FFFFFF#000000##FFFFFF
##42127F1.0012.931.6212.93
#FFFFFF12.931.0021.001.00
#0000001.6221.001.0021.00
##FFFFFF12.931.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003282
Deuteranopia (green-blind)
#00307D
Tritanopia (blue-blind)
#30334A
Achromatopsia (no color)
#313131

Design tokens & code

CSS
--color: #42127f;
/* rgb */ color: rgb(66, 18, 127);
/* oklch */ color: oklch(33.6% 0.164 295.8);
Tailwind
colors: {
  custom: {
    50: '#7e58a5',
    500: '#42127f',
    950: '#000000',
  },
}
SCSS
$custom: #42127f;
$custom-light: #7e58a5;
$custom-dark: #000000;
JSON
{
  "hex": "#42127f",
  "rgb": {
    "r": 66,
    "g": 18,
    "b": 127
  },
  "hsl": {
    "h": 266.422,
    "s": 75.172,
    "l": 28.431
  },
  "oklch": {
    "l": 0.33564,
    "c": 0.16362,
    "h": 295.8
  },
  "luminance": 0.03123
}

Semantic roles & 50–950 ramp

primary
#42127F
secondary
#7EB538
accent
#F2369F
background
#F8F5FA
surface
#EFE9F4
border
#CAC5CE
text
#0B040F
muted
#7C797F

Preview Lab

Preview with #42127F

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

Preview Lab → · Contrast checker → · Palette generator →

#42127F Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva