#340B4C#340B4C

#340B4C is a dark, moderate violet. Relative luminance 0.015; OKLCH L 26.1% C 0.113 H 309.1°. Best body text is #FFFFFF at 16.18:1 contrast (WCAG AA passes).

Color values

HEX#340B4C
RGBrgb(52, 11, 76)
HSLhsl(278, 75%, 17%)
HSVhsv(278, 86%, 30%)
CMYKcmyk(31.6%, 85.5%, 0%, 70.2%)
CIE-LABlab(12.55, 32.08, -30.79)
CIE-LCHlch(12.55, 44.47, 316.18°)
OKLaboklab(26.06% 0.0711 -0.0874)
OKLCHoklch(26.06% 0.113 309.1)
XYZxyz(2.8401, 1.4913, 6.9743)
Luminance0.0149 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#340B4C #234C0B
analogous
#130B4C #340B4C #4C0B44
triadic
#340B4C #4C340B #0B4C34
tetradic
#340B4C #4C130B #234C0B #0B444C
square
#340B4C #4C130B #234C0B #0B444C
split-complementary
#340B4C #444C0B #0B4C13
monochromatic
#12041B #12041B #340B4C #591381 #7D1AB7

Accessibility & contrast

On white

16.18
#340B4C on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.30
#340B4C on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #340B4C
16.18:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##340B4C#FFFFFF#000000##FFFFFF
##340B4C1.0016.181.3016.18
#FFFFFF16.181.0021.001.00
#0000001.3021.001.0021.00
##FFFFFF16.181.0021.001.00

Color blindness preview

Protanopia (red-blind)
#001F4E
Deuteranopia (green-blind)
#00214B
Tritanopia (blue-blind)
#301B2B
Achromatopsia (no color)
#212121

Design tokens & code

CSS
--color: #340b4c;
/* rgb */ color: rgb(52, 11, 76);
/* oklch */ color: oklch(26.1% 0.113 309.1);
Tailwind
colors: {
  custom: {
    50: '#6f4f7f',
    500: '#340b4c',
    950: '#000000',
  },
}
SCSS
$custom: #340b4c;
$custom-light: #6f4f7f;
$custom-dark: #000000;
JSON
{
  "hex": "#340b4c",
  "rgb": {
    "r": 52,
    "g": 11,
    "b": 76
  },
  "hsl": {
    "h": 277.846,
    "s": 74.713,
    "l": 17.059
  },
  "oklch": {
    "l": 0.26063,
    "c": 0.11267,
    "h": 309.1
  },
  "luminance": 0.01491
}

Semantic roles & 50–950 ramp

primary
#340B4C
secondary
#4D882B
accent
#F1367B
background
#F6F4F7
surface
#ECE7EE
border
#C7C3C9
text
#08020A
muted
#7B787C

Preview Lab

Preview with #340B4C

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

Preview Lab → · Contrast checker → · Palette generator →

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