#40248E#40248E

#40248E is a dark, vivid violet. Relative luminance 0.043; OKLCH L 36.8% C 0.163 H 287.6°. Best body text is #FFFFFF at 11.28:1 contrast (WCAG AA passes).

Color values

HEX#40248E
RGBrgb(64, 36, 142)
HSLhsl(256, 60%, 35%)
HSVhsv(256, 75%, 56%)
CMYKcmyk(54.9%, 74.6%, 0%, 44.3%)
CIE-LABlab(24.65, 40.43, -54.01)
CIE-LCHlch(24.65, 67.47, 306.81°)
OKLaboklab(36.84% 0.0493 -0.1553)
OKLCHoklch(36.84% 0.163 287.6)
XYZxyz(7.6263, 4.3043, 26.0149)
Luminance0.0430 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#40248E #728E24
analogous
#243D8E #40248E #75248E
triadic
#40248E #8E4024 #248E40
tetradic
#40248E #8E243D #728E24 #248E75
square
#40248E #8E243D #728E24 #248E75
split-complementary
#40248E #8E7524 #3D8E24
monochromatic
#140B2C #2A185D #40248E #5630BF #7958D5

Accessibility & contrast

On white

11.28
#40248E on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.86
#40248E on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #40248E
11.28:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##40248E#FFFFFF#000000##FFFFFF
##40248E1.0011.281.8611.28
#FFFFFF11.281.0021.001.00
#0000001.8621.001.0021.00
##FFFFFF11.281.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003D91
Deuteranopia (green-blind)
#00388C
Tritanopia (blue-blind)
#204157
Achromatopsia (no color)
#3B3B3B

Design tokens & code

CSS
--color: #40248e;
/* rgb */ color: rgb(64, 36, 142);
/* oklch */ color: oklch(36.8% 0.163 287.6);
Tailwind
colors: {
  custom: {
    50: '#7e62b0',
    500: '#40248e',
    950: '#000000',
  },
}
SCSS
$custom: #40248e;
$custom-light: #7e62b0;
$custom-dark: #000000;
JSON
{
  "hex": "#40248e",
  "rgb": {
    "r": 64,
    "g": 36,
    "b": 142
  },
  "hsl": {
    "h": 255.849,
    "s": 59.551,
    "l": 34.902
  },
  "oklch": {
    "l": 0.36836,
    "c": 0.16296,
    "h": 287.6
  },
  "luminance": 0.04305
}

Semantic roles & 50–950 ramp

primary
#40248E
secondary
#9FB955
accent
#E345B9
background
#F8F5FB
surface
#EFEAF6
border
#CAC6D0
text
#0B0511
muted
#7C7980

Preview Lab

Preview with #40248E

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

Preview Lab → · Contrast checker → · Palette generator →

#40248E Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva