#240A42#240A42

#240A42 is a very dark, moderate violet. Relative luminance 0.010; OKLCH L 22.6% C 0.098 H 299.4°. Best body text is #FFFFFF at 17.54:1 contrast (WCAG AA passes).

Color values

HEX#240A42
RGBrgb(36, 10, 66)
HSLhsl(268, 74%, 15%)
HSVhsv(268, 85%, 26%)
CMYKcmyk(45.5%, 84.8%, 0%, 74.1%)
CIE-LABlab(8.87, 26.55, -29.90)
CIE-LCHlch(8.87, 39.99, 311.60°)
OKLaboklab(22.64% 0.0482 -0.0855)
OKLCHoklch(22.64% 0.098 299.4)
XYZxyz(1.8192, 0.9855, 5.2476)
Luminance0.0098 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#240A42 #28420A
analogous
#0A0C42 #240A42 #400A42
triadic
#240A42 #42240A #0A4224
tetradic
#240A42 #420A0C #28420A #0A4240
square
#240A42 #420A0C #28420A #0A4240
split-complementary
#240A42 #42400A #0C420A
monochromatic
#0E041B #0E041B #240A42 #411277 #5E1AAC

Accessibility & contrast

On white

17.54
#240A42 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.20
#240A42 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #240A42
17.54:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##240A42#FFFFFF#000000##FFFFFF
##240A421.0017.541.2017.54
#FFFFFF17.541.0021.001.00
#0000001.2021.001.0021.00
##FFFFFF17.541.0021.001.00

Color blindness preview

Protanopia (red-blind)
#001944
Deuteranopia (green-blind)
#001941
Tritanopia (blue-blind)
#1D1925
Achromatopsia (no color)
#191919

Design tokens & code

CSS
--color: #240a42;
/* rgb */ color: rgb(36, 10, 66);
/* oklch */ color: oklch(22.6% 0.098 299.4);
Tailwind
colors: {
  custom: {
    50: '#634c77',
    500: '#240a42',
    950: '#000000',
  },
}
SCSS
$custom: #240a42;
$custom-light: #634c77;
$custom-dark: #000000;
JSON
{
  "hex": "#240a42",
  "rgb": {
    "r": 36,
    "g": 10,
    "b": 66
  },
  "hsl": {
    "h": 267.857,
    "s": 73.684,
    "l": 14.902
  },
  "oklch": {
    "l": 0.22637,
    "c": 0.09813,
    "h": 299.4
  },
  "luminance": 0.00985
}

Semantic roles & 50–950 ramp

primary
#240A42
secondary
#577F29
accent
#F0379B
background
#F6F4F7
surface
#EBE7ED
border
#C6C3C8
text
#050109
muted
#7A777B

Preview Lab

Preview with #240A42

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

Preview Lab → · Contrast checker → · Palette generator →

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