#40258A#40258A

#40258A is a dark, vivid violet. Relative luminance 0.042; OKLCH L 36.6% C 0.157 H 288.3°. Best body text is #FFFFFF at 11.35:1 contrast (WCAG AA passes).

Color values

HEX#40258A
RGBrgb(64, 37, 138)
HSLhsl(256, 58%, 34%)
HSVhsv(256, 73%, 54%)
CMYKcmyk(53.6%, 73.2%, 0%, 45.9%)
CIE-LABlab(24.47, 38.68, -51.82)
CIE-LCHlch(24.47, 64.66, 306.74°)
OKLaboklab(36.6% 0.0494 -0.1489)
OKLCHoklch(36.6% 0.157 288.3)
XYZxyz(7.3620, 4.2478, 24.4718)
Luminance0.0425 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#40258A #6F8A25
analogous
#253C8A #40258A #73258A
triadic
#40258A #8A4025 #258A40
tetradic
#40258A #8A253C #6F8A25 #258A73
square
#40258A #8A253C #6F8A25 #258A73
split-complementary
#40258A #8A7325 #3C8A25
monochromatic
#130B29 #2A185A #40258A #5632BA #7857D2

Accessibility & contrast

On white

11.35
#40258A on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.85
#40258A on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #40258A
11.35:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##40258A#FFFFFF#000000##FFFFFF
##40258A1.0011.351.8511.35
#FFFFFF11.351.0021.001.00
#0000001.8521.001.0021.00
##FFFFFF11.351.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003C8D
Deuteranopia (green-blind)
#003788
Tritanopia (blue-blind)
#244055
Achromatopsia (no color)
#3A3A3A

Design tokens & code

CSS
--color: #40258a;
/* rgb */ color: rgb(64, 37, 138);
/* oklch */ color: oklch(36.6% 0.157 288.3);
Tailwind
colors: {
  custom: {
    50: '#7d62ad',
    500: '#40258a',
    950: '#000000',
  },
}
SCSS
$custom: #40258a;
$custom-light: #7d62ad;
$custom-dark: #000000;
JSON
{
  "hex": "#40258a",
  "rgb": {
    "r": 64,
    "g": 37,
    "b": 138
  },
  "hsl": {
    "h": 256.04,
    "s": 57.714,
    "l": 34.314
  },
  "oklch": {
    "l": 0.36595,
    "c": 0.15685,
    "h": 288.3
  },
  "luminance": 0.04248
}

Semantic roles & 50–950 ramp

primary
#40258A
secondary
#9CB754
accent
#E147B8
background
#F8F5FA
surface
#EFEAF4
border
#CAC6CE
text
#0A0510
muted
#7C797F

Preview Lab

Preview with #40258A

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

Preview Lab → · Contrast checker → · Palette generator →

#40258A Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva