#40339A#40339A

#40339A is a dark, vivid blue. Relative luminance 0.058; OKLCH L 40.2% C 0.160 H 282.1°. Best body text is #FFFFFF at 9.73:1 contrast (WCAG AA passes).

Color values

HEX#40339A
RGBrgb(64, 51, 154)
HSLhsl(248, 50%, 40%)
HSVhsv(248, 67%, 60%)
CMYKcmyk(58.4%, 66.9%, 0%, 39.6%)
CIE-LABlab(28.88, 35.55, -54.48)
CIE-LCHlch(28.88, 65.05, 303.12°)
OKLaboklab(40.19% 0.0337 -0.1567)
OKLCHoklch(40.19% 0.16 282.1)
XYZxyz(9.1291, 5.7901, 31.2021)
Luminance0.0579 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#40339A #8D9A33
analogous
#33599A #40339A #74339A
triadic
#40339A #9A4033 #339A40
tetradic
#40339A #9A3359 #8D9A33 #339A74
square
#40339A #9A3359 #8D9A33 #339A74
split-complementary
#40339A #9A7433 #599A33
monochromatic
#1A153E #2D246C #40339A #5748C2 #8176D2

Accessibility & contrast

On white

9.73
#40339A on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.16
#40339A on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #40339A
9.73:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##40339A#FFFFFF#000000##FFFFFF
##40339A1.009.732.169.73
#FFFFFF9.731.0021.001.00
#0000002.1621.001.0021.00
##FFFFFF9.731.0021.001.00

Color blindness preview

Protanopia (red-blind)
#00489D
Deuteranopia (green-blind)
#004098
Tritanopia (blue-blind)
#0D4D62
Achromatopsia (no color)
#444444

Design tokens & code

CSS
--color: #40339a;
/* rgb */ color: rgb(64, 51, 154);
/* oklch */ color: oklch(40.2% 0.160 282.1);
Tailwind
colors: {
  custom: {
    50: '#7f6cb9',
    500: '#40339a',
    950: '#000000',
  },
}
SCSS
$custom: #40339a;
$custom-light: #7f6cb9;
$custom-dark: #000000;
JSON
{
  "hex": "#40339a",
  "rgb": {
    "r": 64,
    "g": 51,
    "b": 154
  },
  "hsl": {
    "h": 247.573,
    "s": 50.244,
    "l": 40.196
  },
  "oklch": {
    "l": 0.40193,
    "c": 0.16032,
    "h": 282.1
  },
  "luminance": 0.05791
}

Semantic roles & 50–950 ramp

primary
#40339A
secondary
#B0BA6F
accent
#DA4EC8
background
#F8F6FB
surface
#EFEBF6
border
#CAC6D0
text
#0B0711
muted
#7C7A80

Preview Lab

Preview with #40339A

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

Preview Lab → · Contrast checker → · Palette generator →

#40339A Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva