#240D42#240D42

#240D42 is a very dark, moderate violet. Relative luminance 0.011; OKLCH L 23.0% C 0.094 H 298.5°. Best body text is #FFFFFF at 17.34:1 contrast (WCAG AA passes).

Color values

HEX#240D42
RGBrgb(36, 13, 66)
HSLhsl(266, 67%, 15%)
HSVhsv(266, 80%, 26%)
CMYKcmyk(45.5%, 80.3%, 0%, 74.1%)
CIE-LABlab(9.45, 24.91, -28.96)
CIE-LCHlch(9.45, 38.19, 310.70°)
OKLaboklab(23.05% 0.0449 -0.0827)
OKLCHoklch(23.05% 0.094 298.5)
XYZxyz(1.8546, 1.0562, 5.2594)
Luminance0.0106 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#240D42 #2B420D
analogous
#0D1042 #240D42 #3E0D42
triadic
#240D42 #42240D #0D4224
tetradic
#240D42 #420D10 #2B420D #0D423E
square
#240D42 #420D10 #2B420D #0D423E
split-complementary
#240D42 #423E0D #10420D
monochromatic
#0E051A #0E051A #240D42 #401775 #5C21A8

Accessibility & contrast

On white

17.34
#240D42 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.21
#240D42 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #240D42
17.34:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##240D42#FFFFFF#000000##FFFFFF
##240D421.0017.341.2117.34
#FFFFFF17.341.0021.001.00
#0000001.2121.001.0021.00
##FFFFFF17.341.0021.001.00

Color blindness preview

Protanopia (red-blind)
#001A44
Deuteranopia (green-blind)
#001A41
Tritanopia (blue-blind)
#1D1A26
Achromatopsia (no color)
#1A1A1A

Design tokens & code

CSS
--color: #240d42;
/* rgb */ color: rgb(36, 13, 66);
/* oklch */ color: oklch(23.0% 0.094 298.5);
Tailwind
colors: {
  custom: {
    50: '#624e77',
    500: '#240d42',
    950: '#000000',
  },
}
SCSS
$custom: #240d42;
$custom-light: #624e77;
$custom-dark: #000000;
JSON
{
  "hex": "#240d42",
  "rgb": {
    "r": 36,
    "g": 13,
    "b": 66
  },
  "hsl": {
    "h": 266.038,
    "s": 67.089,
    "l": 15.49
  },
  "oklch": {
    "l": 0.23047,
    "c": 0.0941,
    "h": 298.5
  },
  "luminance": 0.01056
}

Semantic roles & 50–950 ramp

primary
#240D42
secondary
#5B7E2D
accent
#EA3E9F
background
#F6F4F7
surface
#EBE7ED
border
#C6C3C8
text
#050108
muted
#7A777B

Preview Lab

Preview with #240D42

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

Preview Lab → · Contrast checker → · Palette generator →

#240D42 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva