#402BAA#402BAA

#402BAA is a dark, vivid blue. Relative luminance 0.057; OKLCH L 40.5% C 0.190 H 281.3°. Best body text is #FFFFFF at 9.79:1 contrast (WCAG AA passes).

Color values

HEX#402BAA
RGBrgb(64, 43, 170)
HSLhsl(250, 60%, 42%)
HSVhsv(250, 75%, 67%)
CMYKcmyk(62.4%, 74.7%, 0%, 33.3%)
CIE-LABlab(28.69, 45.21, -64.48)
CIE-LCHlch(28.69, 78.75, 305.04°)
OKLaboklab(40.51% 0.0373 -0.186)
OKLCHoklch(40.51% 0.19 281.3)
XYZxyz(10.2316, 5.7193, 38.5872)
Luminance0.0572 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#402BAA #95AA2B
analogous
#2B56AA #402BAA #802BAA
triadic
#402BAA #AA402B #2BAA40
tetradic
#402BAA #AA2B56 #95AA2B #2BAA80
square
#402BAA #AA2B56 #95AA2B #2BAA80
split-complementary
#402BAA #AA802B #56AA2B
monochromatic
#1B1248 #2E1F79 #402BAA #5A43CF #8574DC

Accessibility & contrast

On white

9.79
#402BAA on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.14
#402BAA on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #402BAA
9.79:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##402BAA#FFFFFF#000000##FFFFFF
##402BAA1.009.792.149.79
#FFFFFF9.791.0021.001.00
#0000002.1421.001.0021.00
##FFFFFF9.791.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0048AE
Deuteranopia (green-blind)
#003FA8
Tritanopia (blue-blind)
#004F68
Achromatopsia (no color)
#444444

Design tokens & code

CSS
--color: #402baa;
/* rgb */ color: rgb(64, 43, 170);
/* oklch */ color: oklch(40.5% 0.190 281.3);
Tailwind
colors: {
  custom: {
    50: '#8267c4',
    500: '#402baa',
    950: '#000000',
  },
}
SCSS
$custom: #402baa;
$custom-light: #8267c4;
$custom-dark: #000000;
JSON
{
  "hex": "#402baa",
  "rgb": {
    "r": 64,
    "g": 43,
    "b": 170
  },
  "hsl": {
    "h": 249.921,
    "s": 59.624,
    "l": 41.765
  },
  "oklch": {
    "l": 0.40513,
    "c": 0.18967,
    "h": 281.3
  },
  "luminance": 0.0572
}

Semantic roles & 50–950 ramp

primary
#402BAA
secondary
#B5C36E
accent
#E345C9
background
#F8F6FC
surface
#F0EBF8
border
#CBC6D1
text
#0C0613
muted
#7D7A82

Preview Lab

Preview with #402BAA

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

Preview Lab → · Contrast checker → · Palette generator →

#402BAA Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva