#2E40A3#2E40A3

#2E40A3 is a dark, vivid blue. Relative luminance 0.069; OKLCH L 42.1% C 0.160 H 270.1°. Best body text is #FFFFFF at 8.83:1 contrast (WCAG AA passes).

Color values

HEX#2E40A3
RGBrgb(46, 64, 163)
HSLhsl(231, 56%, 41%)
HSVhsv(231, 72%, 64%)
CMYKcmyk(71.8%, 60.7%, 0%, 36.1%)
CIE-LABlab(31.56, 27.61, -55.62)
CIE-LCHlch(31.56, 62.09, 296.40°)
OKLaboklab(42.07% 0.0003 -0.1605)
OKLCHoklch(42.07% 0.16 270.1)
XYZxyz(9.5687, 6.8910, 35.4690)
Luminance0.0689 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2E40A3 #A3912E
analogous
#2E7AA3 #2E40A3 #562EA3
triadic
#2E40A3 #A32E40 #40A32E
tetradic
#2E40A3 #A32E7A #A3912E #2EA356
square
#2E40A3 #A32E7A #A3912E #2EA356
split-complementary
#2E40A3 #A3562E #7AA32E
monochromatic
#131B44 #212D73 #2E40A3 #4459CA #7483D8

Accessibility & contrast

On white

8.83
#2E40A3 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.38
#2E40A3 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #2E40A3
8.83:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2E40A3#FFFFFF#000000##FFFFFF
##2E40A31.008.832.388.83
#FFFFFF8.831.0021.001.00
#0000002.3821.001.0021.00
##FFFFFF8.831.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0050A6
Deuteranopia (green-blind)
#0045A1
Tritanopia (blue-blind)
#00596B
Achromatopsia (no color)
#4A4A4A

Design tokens & code

CSS
--color: #2e40a3;
/* rgb */ color: rgb(46, 64, 163);
/* oklch */ color: oklch(42.1% 0.160 270.1);
Tailwind
colors: {
  custom: {
    50: '#7774bf',
    500: '#2e40a3',
    950: '#000000',
  },
}
SCSS
$custom: #2e40a3;
$custom-light: #7774bf;
$custom-dark: #000000;
JSON
{
  "hex": "#2e40a3",
  "rgb": {
    "r": 46,
    "g": 64,
    "b": 163
  },
  "hsl": {
    "h": 230.769,
    "s": 55.981,
    "l": 40.98
  },
  "oklch": {
    "l": 0.42071,
    "c": 0.16047,
    "h": 270.1
  },
  "luminance": 0.06892
}

Semantic roles & 50–950 ramp

primary
#2E40A3
secondary
#BFB36D
accent
#C849DF
background
#F7F7FB
surface
#EEEDF7
border
#C9C8D0
text
#0A0812
muted
#7C7B81

Preview Lab

Preview with #2E40A3

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

Preview Lab → · Contrast checker → · Palette generator →

#2E40A3 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva