#340E42#340E42

#340E42 is a dark, moderate purple. Relative luminance 0.014; OKLCH L 25.6% C 0.098 H 315.4°. Best body text is #FFFFFF at 16.31:1 contrast (WCAG AA passes).

Color values

HEX#340E42
RGBrgb(52, 14, 66)
HSLhsl(284, 65%, 16%)
HSVhsv(284, 79%, 26%)
CMYKcmyk(21.2%, 78.8%, 0%, 74.1%)
CIE-LABlab(12.21, 28.23, -24.38)
CIE-LCHlch(12.21, 37.30, 319.19°)
OKLaboklab(25.56% 0.0695 -0.0686)
OKLCHoklch(25.56% 0.098 315.4)
XYZxyz(2.5564, 1.4376, 5.2960)
Luminance0.0144 (WCAG relative)
Temperaturecool
Familypurple

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#340E42 #1C420E
analogous
#1A0E42 #340E42 #420E36
triadic
#340E42 #42340E #0E4234
tetradic
#340E42 #421A0E #1C420E #0E3642
square
#340E42 #421A0E #1C420E #0E3642
split-complementary
#340E42 #36420E #0E421A
monochromatic
#140519 #140519 #340E42 #5C1974 #8423A7

Accessibility & contrast

On white

16.31
#340E42 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.29
#340E42 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #340E42
16.31:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##340E42#FFFFFF#000000##FFFFFF
##340E421.0016.311.2916.31
#FFFFFF16.311.0021.001.00
#0000001.2921.001.0021.00
##FFFFFF16.311.0021.001.00

Color blindness preview

Protanopia (red-blind)
#001E44
Deuteranopia (green-blind)
#0D2141
Tritanopia (blue-blind)
#331926
Achromatopsia (no color)
#202020

Design tokens & code

CSS
--color: #340e42;
/* rgb */ color: rgb(52, 14, 66);
/* oklch */ color: oklch(25.6% 0.098 315.4);
Tailwind
colors: {
  custom: {
    50: '#6e5077',
    500: '#340e42',
    950: '#000000',
  },
}
SCSS
$custom: #340e42;
$custom-light: #6e5077;
$custom-dark: #000000;
JSON
{
  "hex": "#340e42",
  "rgb": {
    "r": 52,
    "g": 14,
    "b": 66
  },
  "hsl": {
    "h": 283.846,
    "s": 65,
    "l": 15.686
  },
  "oklch": {
    "l": 0.25555,
    "c": 0.09766,
    "h": 315.4
  },
  "luminance": 0.01437
}

Semantic roles & 50–950 ramp

primary
#340E42
secondary
#447D2F
accent
#E8406D
background
#F6F4F7
surface
#ECE7ED
border
#C7C3C8
text
#070208
muted
#7A787B

Preview Lab

Preview with #340E42

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

Preview Lab → · Contrast checker → · Palette generator →

#340E42 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva