#340E57#340E57

#340E57 is a dark, vivid violet. Relative luminance 0.017; OKLCH L 27.4% C 0.121 H 302.4°. Best body text is #FFFFFF at 15.60:1 contrast (WCAG AA passes).

Color values

HEX#340E57
RGBrgb(52, 14, 87)
HSLhsl(271, 72%, 20%)
HSVhsv(271, 84%, 34%)
CMYKcmyk(40.2%, 83.9%, 0%, 65.9%)
CIE-LABlab(14.01, 33.63, -35.94)
CIE-LCHlch(14.01, 49.22, 313.10°)
OKLaboklab(27.4% 0.0651 -0.1026)
OKLCHoklch(27.4% 0.121 302.4)
XYZxyz(3.2931, 1.7323, 9.1758)
Luminance0.0173 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#340E57 #31570E
analogous
#100E57 #340E57 #570E56
triadic
#340E57 #57340E #0E5734
tetradic
#340E57 #57100E #31570E #0E5657
square
#340E57 #57100E #31570E #0E5657
split-complementary
#340E57 #56570E #0E5710
monochromatic
#10041A #140622 #340E57 #54168C #731FC0

Accessibility & contrast

On white

15.60
#340E57 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.35
#340E57 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #340E57
15.60:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##340E57#FFFFFF#000000##FFFFFF
##340E571.0015.601.3515.60
#FFFFFF15.601.0021.001.00
#0000001.3521.001.0021.00
##FFFFFF15.601.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002359
Deuteranopia (green-blind)
#002356
Tritanopia (blue-blind)
#2D2132
Achromatopsia (no color)
#242424

Design tokens & code

CSS
--color: #340e57;
/* rgb */ color: rgb(52, 14, 87);
/* oklch */ color: oklch(27.4% 0.121 302.4);
Tailwind
colors: {
  custom: {
    50: '#705187',
    500: '#340e57',
    950: '#000000',
  },
}
SCSS
$custom: #340e57;
$custom-light: #705187;
$custom-dark: #000000;
JSON
{
  "hex": "#340e57",
  "rgb": {
    "r": 52,
    "g": 14,
    "b": 87
  },
  "hsl": {
    "h": 271.233,
    "s": 72.277,
    "l": 19.804
  },
  "oklch": {
    "l": 0.27402,
    "c": 0.12149,
    "h": 302.4
  },
  "luminance": 0.01732
}

Semantic roles & 50–950 ramp

primary
#340E57
secondary
#5E9130
accent
#EF3990
background
#F7F4F8
surface
#EDE7EF
border
#C8C3CA
text
#08020B
muted
#7B787C

Preview Lab

Preview with #340E57

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

Preview Lab → · Contrast checker → · Palette generator →

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