#40135C#40135C

#40135C is a dark, vivid violet. Relative luminance 0.023; OKLCH L 30.1% C 0.124 H 308.8°. Best body text is #FFFFFF at 14.33:1 contrast (WCAG AA passes).

Color values

HEX#40135C
RGBrgb(64, 19, 92)
HSLhsl(277, 66%, 22%)
HSVhsv(277, 79%, 36%)
CMYKcmyk(30.4%, 79.3%, 0%, 63.9%)
CIE-LABlab(17.12, 35.09, -34.16)
CIE-LCHlch(17.12, 48.97, 315.77°)
OKLaboklab(30.13% 0.0778 -0.0969)
OKLCHoklch(30.13% 0.124 308.8)
XYZxyz(4.2786, 2.3285, 10.3472)
Luminance0.0233 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#40135C #2F5C13
analogous
#1B135C #40135C #5C1354
triadic
#40135C #5C4013 #135C40
tetradic
#40135C #5C1B13 #2F5C13 #13545C
square
#40135C #5C1B13 #2F5C13 #13545C
split-complementary
#40135C #545C13 #135C1B
monochromatic
#120519 #1D0929 #40135C #631D8F #8728C1

Accessibility & contrast

On white

14.33
#40135C on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.47
#40135C on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #40135C
14.33:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##40135C#FFFFFF#000000##FFFFFF
##40135C1.0014.331.4714.33
#FFFFFF14.331.0021.001.00
#0000001.4721.001.0021.00
##FFFFFF14.331.0021.001.00

Color blindness preview

Protanopia (red-blind)
#00285E
Deuteranopia (green-blind)
#002B5A
Tritanopia (blue-blind)
#3C2436
Achromatopsia (no color)
#2A2A2A

Design tokens & code

CSS
--color: #40135c;
/* rgb */ color: rgb(64, 19, 92);
/* oklch */ color: oklch(30.1% 0.124 308.8);
Tailwind
colors: {
  custom: {
    50: '#78568b',
    500: '#40135c',
    950: '#000000',
  },
}
SCSS
$custom: #40135c;
$custom-light: #78568b;
$custom-dark: #000000;
JSON
{
  "hex": "#40135c",
  "rgb": {
    "r": 64,
    "g": 19,
    "b": 92
  },
  "hsl": {
    "h": 276.986,
    "s": 65.766,
    "l": 21.765
  },
  "oklch": {
    "l": 0.30125,
    "c": 0.12427,
    "h": 308.8
  },
  "luminance": 0.02328
}

Semantic roles & 50–950 ramp

primary
#40135C
secondary
#5B9437
accent
#E93F80
background
#F7F5F8
surface
#EEE9F0
border
#C9C5CB
text
#09030C
muted
#7B787D

Preview Lab

Preview with #40135C

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

Preview Lab → · Contrast checker → · Palette generator →

#40135C Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva