#2C40A6#2C40A6

#2C40A6 is a dark, vivid blue. Relative luminance 0.070; OKLCH L 42.2% C 0.165 H 269.4°. Best body text is #FFFFFF at 8.78:1 contrast (WCAG AA passes).

Color values

HEX#2C40A6
RGBrgb(44, 64, 166)
HSLhsl(230, 58%, 41%)
HSVhsv(230, 73%, 65%)
CMYKcmyk(73.5%, 61.4%, 0%, 34.9%)
CIE-LABlab(31.70, 28.46, -57.19)
CIE-LCHlch(31.70, 63.88, 296.46°)
OKLaboklab(42.23% -0.0017 -0.1651)
OKLCHoklch(42.23% 0.165 269.4)
XYZxyz(9.7527, 6.9544, 36.8974)
Luminance0.0696 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2C40A6 #A6922C
analogous
#2C7DA6 #2C40A6 #552CA6
triadic
#2C40A6 #A62C40 #40A62C
tetradic
#2C40A6 #A62C7D #A6922C #2CA655
square
#2C40A6 #A62C7D #A6922C #2CA655
split-complementary
#2C40A6 #A6552C #7DA62C
monochromatic
#121B45 #1F2D76 #2C40A6 #4259CD #7384DA

Accessibility & contrast

On white

8.78
#2C40A6 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.39
#2C40A6 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #2C40A6
8.78:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2C40A6#FFFFFF#000000##FFFFFF
##2C40A61.008.782.398.78
#FFFFFF8.781.0021.001.00
#0000002.3921.001.0021.00
##FFFFFF8.781.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0050A9
Deuteranopia (green-blind)
#0045A4
Tritanopia (blue-blind)
#005A6D
Achromatopsia (no color)
#4B4B4B

Design tokens & code

CSS
--color: #2c40a6;
/* rgb */ color: rgb(44, 64, 166);
/* oklch */ color: oklch(42.2% 0.165 269.4);
Tailwind
colors: {
  custom: {
    50: '#7774c1',
    500: '#2c40a6',
    950: '#000000',
  },
}
SCSS
$custom: #2c40a6;
$custom-light: #7774c1;
$custom-dark: #000000;
JSON
{
  "hex": "#2c40a6",
  "rgb": {
    "r": 44,
    "g": 64,
    "b": 166
  },
  "hsl": {
    "h": 230.164,
    "s": 58.095,
    "l": 41.176
  },
  "oklch": {
    "l": 0.42229,
    "c": 0.16514,
    "h": 269.4
  },
  "luminance": 0.06955
}

Semantic roles & 50–950 ramp

primary
#2C40A6
secondary
#C1B36D
accent
#C846E1
background
#F7F7FC
surface
#EEEDF8
border
#C9C8D1
text
#0A0812
muted
#7C7B81

Preview Lab

Preview with #2C40A6

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

Preview Lab → · Contrast checker → · Palette generator →

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