#40397E#40397E

#40397E is a dark, moderate blue. Relative luminance 0.055; OKLCH L 39.0% C 0.113 H 284.5°. Best body text is #FFFFFF at 9.98:1 contrast (WCAG AA passes).

Color values

HEX#40397E
RGBrgb(64, 57, 126)
HSLhsl(246, 38%, 36%)
HSVhsv(246, 55%, 49%)
CMYKcmyk(49.2%, 54.8%, 0%, 50.6%)
CIE-LABlab(28.17, 22.54, -38.31)
CIE-LCHlch(28.17, 44.45, 300.47°)
OKLaboklab(38.99% 0.0282 -0.1091)
OKLCHoklch(38.99% 0.113 284.5)
XYZxyz(7.3423, 5.5223, 20.4136)
Luminance0.0552 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#40397E #777E39
analogous
#39547E #40397E #62397E
triadic
#40397E #7E4039 #397E40
tetradic
#40397E #7E3954 #777E39 #397E62
square
#40397E #7E3954 #777E39 #397E62
split-complementary
#40397E #7E6239 #547E39
monochromatic
#15132A #2B2654 #40397E #554CA8 #7A72BF

Accessibility & contrast

On white

9.98
#40397E on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.10
#40397E on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #40397E
9.98:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##40397E#FFFFFF#000000##FFFFFF
##40397E1.009.982.109.98
#FFFFFF9.981.0021.001.00
#0000002.1021.001.0021.00
##FFFFFF9.981.0021.001.00

Color blindness preview

Protanopia (red-blind)
#164580
Deuteranopia (green-blind)
#13407C
Tritanopia (blue-blind)
#2B4855
Achromatopsia (no color)
#424242

Design tokens & code

CSS
--color: #40397e;
/* rgb */ color: rgb(64, 57, 126);
/* oklch */ color: oklch(39.0% 0.113 284.5);
Tailwind
colors: {
  custom: {
    50: '#796fa4',
    500: '#40397e',
    950: '#000000',
  },
}
SCSS
$custom: #40397e;
$custom-light: #796fa4;
$custom-dark: #000000;
JSON
{
  "hex": "#40397e",
  "rgb": {
    "r": 64,
    "g": 57,
    "b": 126
  },
  "hsl": {
    "h": 246.087,
    "s": 37.705,
    "l": 35.882
  },
  "oklch": {
    "l": 0.38992,
    "c": 0.11272,
    "h": 284.5
  },
  "luminance": 0.05523
}

Semantic roles & 50–950 ramp

primary
#40397E
secondary
#A2A86A
accent
#CE5AC2
background
#F7F6FA
surface
#EEECF4
border
#C9C7CE
text
#09070F
muted
#7B7A7F

Preview Lab

Preview with #40397E

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

Preview Lab → · Contrast checker → · Palette generator →

#40397E Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva