#2A40A1#2A40A1

#2A40A1 is a dark, vivid blue. Relative luminance 0.067; OKLCH L 41.7% C 0.159 H 268.7°. Best body text is #FFFFFF at 8.95:1 contrast (WCAG AA passes).

Color values

HEX#2A40A1
RGBrgb(42, 64, 161)
HSLhsl(229, 59%, 40%)
HSVhsv(229, 74%, 63%)
CMYKcmyk(73.9%, 60.2%, 0%, 36.9%)
CIE-LABlab(31.19, 26.34, -55.02)
CIE-LCHlch(31.19, 61.00, 295.58°)
OKLaboklab(41.69% -0.0037 -0.1588)
OKLCHoklch(41.69% 0.159 268.7)
XYZxyz(9.2190, 6.7313, 34.5247)
Luminance0.0673 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2A40A1 #A18B2A
analogous
#2A7BA1 #2A40A1 #502AA1
triadic
#2A40A1 #A12A40 #40A12A
tetradic
#2A40A1 #A12A7B #A18B2A #2AA150
square
#2A40A1 #A12A7B #A18B2A #2AA150
split-complementary
#2A40A1 #A1502A #7BA12A
monochromatic
#111940 #1D2D70 #2A40A1 #3C57CC #6D81D9

Accessibility & contrast

On white

8.95
#2A40A1 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.35
#2A40A1 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #2A40A1
8.95:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2A40A1#FFFFFF#000000##FFFFFF
##2A40A11.008.952.358.95
#FFFFFF8.951.0021.001.00
#0000002.3521.001.0021.00
##FFFFFF8.951.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004FA4
Deuteranopia (green-blind)
#00449F
Tritanopia (blue-blind)
#00586A
Achromatopsia (no color)
#494949

Design tokens & code

CSS
--color: #2a40a1;
/* rgb */ color: rgb(42, 64, 161);
/* oklch */ color: oklch(41.7% 0.159 268.7);
Tailwind
colors: {
  custom: {
    50: '#7574be',
    500: '#2a40a1',
    950: '#000000',
  },
}
SCSS
$custom: #2a40a1;
$custom-light: #7574be;
$custom-dark: #000000;
JSON
{
  "hex": "#2a40a1",
  "rgb": {
    "r": 42,
    "g": 64,
    "b": 161
  },
  "hsl": {
    "h": 228.908,
    "s": 58.621,
    "l": 39.804
  },
  "oklch": {
    "l": 0.41689,
    "c": 0.15885,
    "h": 268.7
  },
  "luminance": 0.06732
}

Semantic roles & 50–950 ramp

primary
#2A40A1
secondary
#C0AF67
accent
#C546E2
background
#F7F7FB
surface
#EEEDF7
border
#C9C8D0
text
#0A0812
muted
#7C7B81

Preview Lab

Preview with #2A40A1

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

Preview Lab → · Contrast checker → · Palette generator →

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