#3A40B2#3A40B2

#3A40B2 is a dark, vivid blue. Relative luminance 0.078; OKLCH L 44.1% C 0.177 H 274.1°. Best body text is #FFFFFF at 8.22:1 contrast (WCAG AA passes).

Color values

HEX#3A40B2
RGBrgb(58, 64, 178)
HSLhsl(237, 51%, 46%)
HSVhsv(237, 67%, 70%)
CMYKcmyk(67.4%, 64%, 0%, 30.2%)
CIE-LABlab(33.52, 34.65, -61.36)
CIE-LCHlch(33.52, 70.46, 299.45°)
OKLaboklab(44.1% 0.0128 -0.177)
OKLCHoklch(44.1% 0.177 274.1)
XYZxyz(11.6115, 7.7796, 43.0005)
Luminance0.0778 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#3A40B2 #B2AC3A
analogous
#3A7CB2 #3A40B2 #703AB2
triadic
#3A40B2 #B23A40 #40B23A
tetradic
#3A40B2 #B23A7C #B2AC3A #3AB270
square
#3A40B2 #B23A7C #B2AC3A #3AB270
split-complementary
#3A40B2 #B2703A #7CB23A
monochromatic
#1C1F56 #2B2F84 #3A40B2 #5F64CB #8D91DA

Accessibility & contrast

On white

8.22
#3A40B2 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.56
#3A40B2 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #3A40B2
8.22:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##3A40B2#FFFFFF#000000##FFFFFF
##3A40B21.008.222.568.22
#FFFFFF8.221.0021.001.00
#0000002.5621.001.0021.00
##FFFFFF8.221.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0054B6
Deuteranopia (green-blind)
#0049B0
Tritanopia (blue-blind)
#005D73
Achromatopsia (no color)
#4F4F4F

Design tokens & code

CSS
--color: #3a40b2;
/* rgb */ color: rgb(58, 64, 178);
/* oklch */ color: oklch(44.1% 0.177 274.1);
Tailwind
colors: {
  custom: {
    50: '#7f75ca',
    500: '#3a40b2',
    950: '#000000',
  },
}
SCSS
$custom: #3a40b2;
$custom-light: #7f75ca;
$custom-dark: #000000;
JSON
{
  "hex": "#3a40b2",
  "rgb": {
    "r": 58,
    "g": 64,
    "b": 178
  },
  "hsl": {
    "h": 237,
    "s": 50.847,
    "l": 46.275
  },
  "oklch": {
    "l": 0.44096,
    "c": 0.17749,
    "h": 274.1
  },
  "luminance": 0.07781
}

Semantic roles & 50–950 ramp

primary
#3A40B2
secondary
#C4C183
accent
#D34DDA
background
#F8F7FC
surface
#EFEDF8
border
#CAC8D1
text
#0B0813
muted
#7C7B82

Preview Lab

Preview with #3A40B2

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

Preview Lab → · Contrast checker → · Palette generator →

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