#240F5A#240F5A

#240F5A is a dark, vivid violet. Relative luminance 0.015; OKLCH L 25.8% C 0.123 H 287.0°. Best body text is #FFFFFF at 16.27:1 contrast (WCAG AA passes).

Color values

HEX#240F5A
RGBrgb(36, 15, 90)
HSLhsl(257, 71%, 21%)
HSVhsv(257, 83%, 35%)
CMYKcmyk(60%, 83.3%, 0%, 64.7%)
CIE-LABlab(12.32, 31.31, -40.83)
CIE-LCHlch(12.32, 51.45, 307.49°)
OKLaboklab(25.82% 0.036 -0.1175)
OKLCHoklch(25.82% 0.123 287)
XYZxyz(2.7433, 1.4548, 9.8071)
Luminance0.0146 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#240F5A #455A0F
analogous
#0F1F5A #240F5A #490F5A
triadic
#240F5A #5A240F #0F5A24
tetradic
#240F5A #5A0F1F #455A0F #0F5A49
square
#240F5A #5A0F1F #455A0F #0F5A49
split-complementary
#240F5A #5A490F #1F5A0F
monochromatic
#0A041A #0F0626 #240F5A #39188E #4E20C3

Accessibility & contrast

On white

16.27
#240F5A on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.29
#240F5A on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #240F5A
16.27:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##240F5A#FFFFFF#000000##FFFFFF
##240F5A1.0016.271.2916.27
#FFFFFF16.271.0021.001.00
#0000001.2921.001.0021.00
##FFFFFF16.271.0021.001.00

Color blindness preview

Protanopia (red-blind)
#00225C
Deuteranopia (green-blind)
#001E59
Tritanopia (blue-blind)
#0B2534
Achromatopsia (no color)
#202020

Design tokens & code

CSS
--color: #240f5a;
/* rgb */ color: rgb(36, 15, 90);
/* oklch */ color: oklch(25.8% 0.123 287.0);
Tailwind
colors: {
  custom: {
    50: '#665089',
    500: '#240f5a',
    950: '#000000',
  },
}
SCSS
$custom: #240f5a;
$custom-light: #665089;
$custom-dark: #000000;
JSON
{
  "hex": "#240f5a",
  "rgb": {
    "r": 36,
    "g": 15,
    "b": 90
  },
  "hsl": {
    "h": 256.8,
    "s": 71.429,
    "l": 20.588
  },
  "oklch": {
    "l": 0.25823,
    "c": 0.12292,
    "h": 287
  },
  "luminance": 0.01455
}

Semantic roles & 50–950 ramp

primary
#240F5A
secondary
#789431
accent
#EE3ABC
background
#F6F4F8
surface
#EBE7F0
border
#C6C3CB
text
#06020C
muted
#7A787D

Preview Lab

Preview with #240F5A

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

Preview Lab → · Contrast checker → · Palette generator →

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