#340B52#340B52

#340B52 is a dark, moderate violet. Relative luminance 0.016; OKLCH L 26.6% C 0.119 H 305.6°. Best body text is #FFFFFF at 15.96:1 contrast (WCAG AA passes).

Color values

HEX#340B52
RGBrgb(52, 11, 82)
HSLhsl(275, 76%, 18%)
HSVhsv(275, 87%, 32%)
CMYKcmyk(36.6%, 86.6%, 0%, 67.8%)
CIE-LABlab(13.10, 33.61, -34.03)
CIE-LCHlch(13.10, 47.83, 314.64°)
OKLaboklab(26.62% 0.0694 -0.0969)
OKLCHoklch(26.62% 0.119 305.6)
XYZxyz(3.0585, 1.5786, 8.1246)
Luminance0.0158 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#340B52 #29520B
analogous
#100B52 #340B52 #520B4C
triadic
#340B52 #52340B #0B5234
tetradic
#340B52 #52100B #29520B #0B4C52
square
#340B52 #52100B #29520B #0B4C52
split-complementary
#340B52 #4C520B #0B5210
monochromatic
#11041B #12041C #340B52 #561288 #7819BE

Accessibility & contrast

On white

15.96
#340B52 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.32
#340B52 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #340B52
15.96:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##340B52#FFFFFF#000000##FFFFFF
##340B521.0015.961.3215.96
#FFFFFF15.961.0021.001.00
#0000001.3221.001.0021.00
##FFFFFF15.961.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002154
Deuteranopia (green-blind)
#002251
Tritanopia (blue-blind)
#2E1E2F
Achromatopsia (no color)
#222222

Design tokens & code

CSS
--color: #340b52;
/* rgb */ color: rgb(52, 11, 82);
/* oklch */ color: oklch(26.6% 0.119 305.6);
Tailwind
colors: {
  custom: {
    50: '#6f5083',
    500: '#340b52',
    950: '#000000',
  },
}
SCSS
$custom: #340b52;
$custom-light: #6f5083;
$custom-dark: #000000;
JSON
{
  "hex": "#340b52",
  "rgb": {
    "r": 52,
    "g": 11,
    "b": 82
  },
  "hsl": {
    "h": 274.648,
    "s": 76.344,
    "l": 18.235
  },
  "oklch": {
    "l": 0.26617,
    "c": 0.11921,
    "h": 305.6
  },
  "luminance": 0.01579
}

Semantic roles & 50–950 ramp

primary
#340B52
secondary
#558E2B
accent
#F33585
background
#F6F4F8
surface
#ECE7EF
border
#C7C3CA
text
#08020B
muted
#7B787C

Preview Lab

Preview with #340B52

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

Preview Lab → · Contrast checker → · Palette generator →

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