#340C4D#340C4D

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

Color values

HEX#340C4D
RGBrgb(52, 12, 77)
HSLhsl(277, 73%, 17%)
HSVhsv(277, 84%, 30%)
CMYKcmyk(32.5%, 84.4%, 0%, 69.8%)
CIE-LABlab(12.79, 31.91, -31.10)
CIE-LCHlch(12.79, 44.55, 315.74°)
OKLaboklab(26.26% 0.0698 -0.0883)
OKLCHoklch(26.26% 0.113 308.3)
XYZxyz(2.8869, 1.5289, 7.1628)
Luminance0.0153 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#340C4D #254D0C
analogous
#130C4D #340C4D #4D0C46
triadic
#340C4D #4D340C #0C4D34
tetradic
#340C4D #4D130C #254D0C #0C464D
square
#340C4D #4D130C #254D0C #0C464D
split-complementary
#340C4D #464D0C #0C4D13
monochromatic
#12041A #12041A #340C4D #581482 #7C1DB7

Accessibility & contrast

On white

16.08
#340C4D on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.31
#340C4D on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #340C4D
16.08:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##340C4D#FFFFFF#000000##FFFFFF
##340C4D1.0016.081.3116.08
#FFFFFF16.081.0021.001.00
#0000001.3121.001.0021.00
##FFFFFF16.081.0021.001.00

Color blindness preview

Protanopia (red-blind)
#00204F
Deuteranopia (green-blind)
#00224C
Tritanopia (blue-blind)
#301C2C
Achromatopsia (no color)
#212121

Design tokens & code

CSS
--color: #340c4d;
/* rgb */ color: rgb(52, 12, 77);
/* oklch */ color: oklch(26.3% 0.113 308.3);
Tailwind
colors: {
  custom: {
    50: '#6f507f',
    500: '#340c4d',
    950: '#000000',
  },
}
SCSS
$custom: #340c4d;
$custom-light: #6f507f;
$custom-dark: #000000;
JSON
{
  "hex": "#340c4d",
  "rgb": {
    "r": 52,
    "g": 12,
    "b": 77
  },
  "hsl": {
    "h": 276.923,
    "s": 73.034,
    "l": 17.451
  },
  "oklch": {
    "l": 0.26258,
    "c": 0.11259,
    "h": 308.3
  },
  "luminance": 0.01529
}

Semantic roles & 50–950 ramp

primary
#340C4D
secondary
#50892C
accent
#F0387F
background
#F6F4F7
surface
#ECE7EE
border
#C7C3C9
text
#08020A
muted
#7B787C

Preview Lab

Preview with #340C4D

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

Preview Lab → · Contrast checker → · Palette generator →

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