#40267B#40267B

#40267B is a dark, vivid violet. Relative luminance 0.039; OKLCH L 35.4% C 0.136 H 292.0°. Best body text is #FFFFFF at 11.79:1 contrast (WCAG AA passes).

Color values

HEX#40267B
RGBrgb(64, 38, 123)
HSLhsl(258, 53%, 32%)
HSVhsv(258, 69%, 48%)
CMYKcmyk(48%, 69.1%, 0%, 51.8%)
CIE-LABlab(23.36, 33.57, -44.20)
CIE-LCHlch(23.36, 55.50, 307.22°)
OKLaboklab(35.39% 0.0511 -0.1265)
OKLCHoklch(35.39% 0.136 292)
XYZxyz(6.3816, 3.9061, 19.1528)
Luminance0.0391 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#40267B #617B26
analogous
#26377B #40267B #6B267B
triadic
#40267B #7B4026 #267B40
tetradic
#40267B #7B2637 #617B26 #267B6B
square
#40267B #7B2637 #617B26 #267B6B
split-complementary
#40267B #7B6B26 #377B26
monochromatic
#0F091D #28184C #40267B #5834AA #7652CA

Accessibility & contrast

On white

11.79
#40267B on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.78
#40267B on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #40267B
11.79:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##40267B#FFFFFF#000000##FFFFFF
##40267B1.0011.791.7811.79
#FFFFFF11.791.0021.001.00
#0000001.7821.001.0021.00
##FFFFFF11.791.0021.001.00

Color blindness preview

Protanopia (red-blind)
#00397E
Deuteranopia (green-blind)
#003679
Tritanopia (blue-blind)
#2E3B4D
Achromatopsia (no color)
#383838

Design tokens & code

CSS
--color: #40267b;
/* rgb */ color: rgb(64, 38, 123);
/* oklch */ color: oklch(35.4% 0.136 292.0);
Tailwind
colors: {
  custom: {
    50: '#7a62a2',
    500: '#40267b',
    950: '#000000',
  },
}
SCSS
$custom: #40267b;
$custom-light: #7a62a2;
$custom-dark: #000000;
JSON
{
  "hex": "#40267b",
  "rgb": {
    "r": 64,
    "g": 38,
    "b": 123
  },
  "hsl": {
    "h": 258.353,
    "s": 52.795,
    "l": 31.569
  },
  "oklch": {
    "l": 0.35387,
    "c": 0.13645,
    "h": 292
  },
  "luminance": 0.03906
}

Semantic roles & 50–950 ramp

primary
#40267B
secondary
#91AD50
accent
#DC4CB0
background
#F7F5FA
surface
#EEEAF3
border
#C9C6CD
text
#0A050F
muted
#7C797F

Preview Lab

Preview with #40267B

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

Preview Lab → · Contrast checker → · Palette generator →

#40267B Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva