#40248C#40248C

#40248C is a dark, vivid violet. Relative luminance 0.042; OKLCH L 36.6% C 0.161 H 288.1°. Best body text is #FFFFFF at 11.36:1 contrast (WCAG AA passes).

Color values

HEX#40248C
RGBrgb(64, 36, 140)
HSLhsl(256, 59%, 35%)
HSVhsv(256, 74%, 55%)
CMYKcmyk(54.3%, 74.3%, 0%, 45.1%)
CIE-LABlab(24.46, 39.83, -53.08)
CIE-LCHlch(24.46, 66.36, 306.88°)
OKLaboklab(36.65% 0.0498 -0.1526)
OKLCHoklch(36.65% 0.161 288.1)
XYZxyz(7.4775, 4.2448, 25.2312)
Luminance0.0425 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#40248C #708C24
analogous
#243C8C #40248C #74248C
triadic
#40248C #8C4024 #248C40
tetradic
#40248C #8C243C #708C24 #248C74
square
#40248C #8C243C #708C24 #248C74
split-complementary
#40248C #8C7424 #3C8C24
monochromatic
#130B2B #2A175B #40248C #5631BD #7857D4

Accessibility & contrast

On white

11.36
#40248C on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.85
#40248C on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #40248C
11.36:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##40248C#FFFFFF#000000##FFFFFF
##40248C1.0011.361.8511.36
#FFFFFF11.361.0021.001.00
#0000001.8521.001.0021.00
##FFFFFF11.361.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003C8F
Deuteranopia (green-blind)
#00378A
Tritanopia (blue-blind)
#224056
Achromatopsia (no color)
#3A3A3A

Design tokens & code

CSS
--color: #40248c;
/* rgb */ color: rgb(64, 36, 140);
/* oklch */ color: oklch(36.6% 0.161 288.1);
Tailwind
colors: {
  custom: {
    50: '#7d62af',
    500: '#40248c',
    950: '#000000',
  },
}
SCSS
$custom: #40248c;
$custom-light: #7d62af;
$custom-dark: #000000;
JSON
{
  "hex": "#40248c",
  "rgb": {
    "r": 64,
    "g": 36,
    "b": 140
  },
  "hsl": {
    "h": 256.154,
    "s": 59.091,
    "l": 34.51
  },
  "oklch": {
    "l": 0.36645,
    "c": 0.1605,
    "h": 288.1
  },
  "luminance": 0.04245
}

Semantic roles & 50–950 ramp

primary
#40248C
secondary
#9DB854
accent
#E246B8
background
#F8F5FA
surface
#EFEAF5
border
#CAC6CF
text
#0B0510
muted
#7C797F

Preview Lab

Preview with #40248C

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

Preview Lab → · Contrast checker → · Palette generator →

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