#40255D#40255D

#40255D is a dark, moderate violet. Relative luminance 0.032; OKLCH L 32.8% C 0.098 H 303.7°. Best body text is #FFFFFF at 12.80:1 contrast (WCAG AA passes).

Color values

HEX#40255D
RGBrgb(64, 37, 93)
HSLhsl(269, 43%, 25%)
HSVhsv(269, 60%, 36%)
CMYKcmyk(31.2%, 60.2%, 0%, 63.5%)
CIE-LABlab(20.84, 25.39, -28.84)
CIE-LCHlch(20.84, 38.42, 311.36°)
OKLaboklab(32.83% 0.0543 -0.0814)
OKLCHoklch(32.83% 0.098 303.7)
XYZxyz(4.7513, 3.2034, 10.7218)
Luminance0.0320 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#40255D #425D25
analogous
#25265D #40255D #5C255D
triadic
#40255D #5D4025 #255D40
tetradic
#40255D #5D2526 #425D25 #255D5C
square
#40255D #5D2526 #425D25 #255D5C
split-complementary
#40255D #5D5C25 #265D25
monochromatic
#0F0916 #221431 #40255D #5E3689 #7C48B5

Accessibility & contrast

On white

12.80
#40255D on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.64
#40255D on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #40255D
12.80:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##40255D#FFFFFF#000000##FFFFFF
##40255D1.0012.801.6412.80
#FFFFFF12.801.0021.001.00
#0000001.6421.001.0021.00
##FFFFFF12.801.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0F315F
Deuteranopia (green-blind)
#19325C
Tritanopia (blue-blind)
#3B303D
Achromatopsia (no color)
#323232

Design tokens & code

CSS
--color: #40255d;
/* rgb */ color: rgb(64, 37, 93);
/* oklch */ color: oklch(32.8% 0.098 303.7);
Tailwind
colors: {
  custom: {
    50: '#77618b',
    500: '#40255d',
    950: '#000000',
  },
}
SCSS
$custom: #40255d;
$custom-light: #77618b;
$custom-dark: #000000;
JSON
{
  "hex": "#40255d",
  "rgb": {
    "r": 64,
    "g": 37,
    "b": 93
  },
  "hsl": {
    "h": 268.929,
    "s": 43.077,
    "l": 25.49
  },
  "oklch": {
    "l": 0.32831,
    "c": 0.09784,
    "h": 303.7
  },
  "luminance": 0.03203
}

Semantic roles & 50–950 ramp

primary
#40255D
secondary
#70904D
accent
#D35596
background
#F7F5F8
surface
#EDE9F0
border
#C8C5CB
text
#09050C
muted
#7B797D

Preview Lab

Preview with #40255D

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

Preview Lab → · Contrast checker → · Palette generator →

#40255D Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva