#2E40A2#2E40A2

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

Color values

HEX#2E40A2
RGBrgb(46, 64, 162)
HSLhsl(231, 56%, 41%)
HSVhsv(231, 72%, 64%)
CMYKcmyk(71.6%, 60.5%, 0%, 36.5%)
CIE-LABlab(31.48, 27.24, -55.15)
CIE-LCHlch(31.48, 61.51, 296.29°)
OKLaboklab(41.99% 0.0003 -0.1591)
OKLCHoklch(41.99% 0.159 270.1)
XYZxyz(9.4795, 6.8553, 34.9990)
Luminance0.0686 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2E40A2 #A2902E
analogous
#2E7AA2 #2E40A2 #562EA2
triadic
#2E40A2 #A22E40 #40A22E
tetradic
#2E40A2 #A22E7A #A2902E #2EA256
square
#2E40A2 #A22E7A #A2902E #2EA256
split-complementary
#2E40A2 #A2562E #7AA22E
monochromatic
#131A43 #202D72 #2E40A2 #4358CA #7383D7

Accessibility & contrast

On white

8.86
#2E40A2 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.37
#2E40A2 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #2E40A2
8.86:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2E40A2#FFFFFF#000000##FFFFFF
##2E40A21.008.862.378.86
#FFFFFF8.861.0021.001.00
#0000002.3721.001.0021.00
##FFFFFF8.861.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0050A5
Deuteranopia (green-blind)
#0045A0
Tritanopia (blue-blind)
#00596A
Achromatopsia (no color)
#4A4A4A

Design tokens & code

CSS
--color: #2e40a2;
/* rgb */ color: rgb(46, 64, 162);
/* oklch */ color: oklch(42.0% 0.159 270.1);
Tailwind
colors: {
  custom: {
    50: '#7774be',
    500: '#2e40a2',
    950: '#000000',
  },
}
SCSS
$custom: #2e40a2;
$custom-light: #7774be;
$custom-dark: #000000;
JSON
{
  "hex": "#2e40a2",
  "rgb": {
    "r": 46,
    "g": 64,
    "b": 162
  },
  "hsl": {
    "h": 230.69,
    "s": 55.769,
    "l": 40.784
  },
  "oklch": {
    "l": 0.41985,
    "c": 0.15909,
    "h": 270.1
  },
  "luminance": 0.06856
}

Semantic roles & 50–950 ramp

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

Preview Lab

Preview with #2E40A2

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

Preview Lab → · Contrast checker → · Palette generator →

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