#3A40A2#3A40A2

#3A40A2 is a dark, vivid blue. Relative luminance 0.072; OKLCH L 42.7% C 0.156 H 275.0°. Best body text is #FFFFFF at 8.62:1 contrast (WCAG AA passes).

Color values

HEX#3A40A2
RGBrgb(58, 64, 162)
HSLhsl(237, 47%, 43%)
HSVhsv(237, 64%, 64%)
CMYKcmyk(64.2%, 60.5%, 0%, 36.5%)
CIE-LABlab(32.20, 29.05, -53.94)
CIE-LCHlch(32.20, 61.26, 298.31°)
OKLaboklab(42.71% 0.0136 -0.1552)
OKLCHoklch(42.71% 0.156 275)
XYZxyz(10.0978, 7.1741, 35.0280)
Luminance0.0717 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#3A40A2 #A29C3A
analogous
#3A74A2 #3A40A2 #683AA2
triadic
#3A40A2 #A23A40 #40A23A
tetradic
#3A40A2 #A23A74 #A29C3A #3AA268
square
#3A40A2 #A23A74 #A29C3A #3AA268
split-complementary
#3A40A2 #A2683A #74A23A
monochromatic
#1A1C48 #2A2E75 #3A40A2 #575DC3 #8488D3

Accessibility & contrast

On white

8.62
#3A40A2 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.43
#3A40A2 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #3A40A2
8.62:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##3A40A2#FFFFFF#000000##FFFFFF
##3A40A21.008.622.438.62
#FFFFFF8.621.0021.001.00
#0000002.4321.001.0021.00
##FFFFFF8.621.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0050A5
Deuteranopia (green-blind)
#0047A0
Tritanopia (blue-blind)
#00586A
Achromatopsia (no color)
#4C4C4C

Design tokens & code

CSS
--color: #3a40a2;
/* rgb */ color: rgb(58, 64, 162);
/* oklch */ color: oklch(42.7% 0.156 275.0);
Tailwind
colors: {
  custom: {
    50: '#7c75be',
    500: '#3a40a2',
    950: '#000000',
  },
}
SCSS
$custom: #3a40a2;
$custom-light: #7c75be;
$custom-dark: #000000;
JSON
{
  "hex": "#3a40a2",
  "rgb": {
    "r": 58,
    "g": 64,
    "b": 162
  },
  "hsl": {
    "h": 236.538,
    "s": 47.273,
    "l": 43.137
  },
  "oklch": {
    "l": 0.42714,
    "c": 0.15582,
    "h": 275
  },
  "luminance": 0.07175
}

Semantic roles & 50–950 ramp

primary
#3A40A2
secondary
#BDB97B
accent
#CF51D7
background
#F8F7FB
surface
#EFEDF7
border
#CAC8D0
text
#0A0812
muted
#7C7B81

Preview Lab

Preview with #3A40A2

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

Preview Lab → · Contrast checker → · Palette generator →

#3A40A2 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva