#2840A5#2840A5

#2840A5 is a dark, vivid blue. Relative luminance 0.068; OKLCH L 41.9% C 0.165 H 268.1°. Best body text is #FFFFFF at 8.87:1 contrast (WCAG AA passes).

Color values

HEX#2840A5
RGBrgb(40, 64, 165)
HSLhsl(228, 61%, 40%)
HSVhsv(228, 76%, 65%)
CMYKcmyk(75.8%, 61.2%, 0%, 35.3%)
CIE-LABlab(31.42, 27.60, -57.05)
CIE-LCHlch(31.42, 63.38, 295.82°)
OKLaboklab(41.94% -0.0055 -0.1648)
OKLCHoklch(41.94% 0.165 268.1)
XYZxyz(9.4976, 6.8335, 36.4085)
Luminance0.0683 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2840A5 #A58D28
analogous
#287EA5 #2840A5 #4E28A5
triadic
#2840A5 #A52840 #40A528
tetradic
#2840A5 #A5287E #A58D28 #28A54E
square
#2840A5 #A5287E #A58D28 #28A54E
split-complementary
#2840A5 #A54E28 #7EA528
monochromatic
#101A42 #1C2D74 #2840A5 #3B57CF #6C81DB

Accessibility & contrast

On white

8.87
#2840A5 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.37
#2840A5 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #2840A5
8.87:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2840A5#FFFFFF#000000##FFFFFF
##2840A51.008.872.378.87
#FFFFFF8.871.0021.001.00
#0000002.3721.001.0021.00
##FFFFFF8.871.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0050A8
Deuteranopia (green-blind)
#0044A3
Tritanopia (blue-blind)
#005A6C
Achromatopsia (no color)
#4A4A4A

Design tokens & code

CSS
--color: #2840a5;
/* rgb */ color: rgb(40, 64, 165);
/* oklch */ color: oklch(41.9% 0.165 268.1);
Tailwind
colors: {
  custom: {
    50: '#7574c1',
    500: '#2840a5',
    950: '#000000',
  },
}
SCSS
$custom: #2840a5;
$custom-light: #7574c1;
$custom-dark: #000000;
JSON
{
  "hex": "#2840a5",
  "rgb": {
    "r": 40,
    "g": 64,
    "b": 165
  },
  "hsl": {
    "h": 228.48,
    "s": 60.976,
    "l": 40.196
  },
  "oklch": {
    "l": 0.41943,
    "c": 0.16489,
    "h": 268.1
  },
  "luminance": 0.06835
}

Semantic roles & 50–950 ramp

primary
#2840A5
secondary
#C2B067
accent
#C544E4
background
#F7F7FC
surface
#EEEDF8
border
#C9C8D1
text
#0A0812
muted
#7C7B81

Preview Lab

Preview with #2840A5

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

Preview Lab → · Contrast checker → · Palette generator →

#2840A5 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva