#40135B#40135B

#40135B is a dark, vivid violet. Relative luminance 0.023; OKLCH L 30.0% C 0.123 H 309.3°. Best body text is #FFFFFF at 14.36:1 contrast (WCAG AA passes).

Color values

HEX#40135B
RGBrgb(64, 19, 91)
HSLhsl(278, 65%, 22%)
HSVhsv(278, 79%, 36%)
CMYKcmyk(29.7%, 79.1%, 0%, 64.3%)
CIE-LABlab(17.04, 34.84, -33.62)
CIE-LCHlch(17.04, 48.42, 316.02°)
OKLaboklab(30.04% 0.078 -0.0953)
OKLCHoklch(30.04% 0.123 309.3)
XYZxyz(4.2352, 2.3111, 10.1185)
Luminance0.0231 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#40135B #2E5B13
analogous
#1C135B #40135B #5B1352
triadic
#40135B #5B4013 #135B40
tetradic
#40135B #5B1C13 #2E5B13 #13525B
square
#40135B #5B1C13 #2E5B13 #13525B
split-complementary
#40135B #525B13 #135B1C
monochromatic
#120519 #1C0828 #40135B #641E8E #8728C0

Accessibility & contrast

On white

14.36
#40135B on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.46
#40135B on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #40135B
14.36:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##40135B#FFFFFF#000000##FFFFFF
##40135B1.0014.361.4614.36
#FFFFFF14.361.0021.001.00
#0000001.4621.001.0021.00
##FFFFFF14.361.0021.001.00

Color blindness preview

Protanopia (red-blind)
#00285D
Deuteranopia (green-blind)
#022B59
Tritanopia (blue-blind)
#3C2436
Achromatopsia (no color)
#2A2A2A

Design tokens & code

CSS
--color: #40135b;
/* rgb */ color: rgb(64, 19, 91);
/* oklch */ color: oklch(30.0% 0.123 309.3);
Tailwind
colors: {
  custom: {
    50: '#78568a',
    500: '#40135b',
    950: '#000000',
  },
}
SCSS
$custom: #40135b;
$custom-light: #78568a;
$custom-dark: #000000;
JSON
{
  "hex": "#40135b",
  "rgb": {
    "r": 64,
    "g": 19,
    "b": 91
  },
  "hsl": {
    "h": 277.5,
    "s": 65.455,
    "l": 21.569
  },
  "oklch": {
    "l": 0.30041,
    "c": 0.12317,
    "h": 309.3
  },
  "luminance": 0.02311
}

Semantic roles & 50–950 ramp

primary
#40135B
secondary
#599337
accent
#E83F7F
background
#F7F5F8
surface
#EEE9F0
border
#C9C5CB
text
#09030C
muted
#7B787D

Preview Lab

Preview with #40135B

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

Preview Lab → · Contrast checker → · Palette generator →

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