#2871C4#2871C4

#2871C4 is a mid, vivid cyan. Relative luminance 0.162; OKLCH L 54.7% C 0.148 H 254.4°. Best body text is #FFFFFF at 4.94:1 contrast (WCAG AA passes).

Color values

HEX#2871C4
RGBrgb(40, 113, 196)
HSLhsl(212, 66%, 46%)
HSVhsv(212, 80%, 77%)
CMYKcmyk(79.6%, 42.3%, 0%, 23.1%)
CIE-LABlab(47.29, 7.45, -49.64)
CIE-LCHlch(47.29, 50.19, 278.54°)
OKLaboklab(54.73% -0.0397 -0.1421)
OKLCHoklch(54.73% 0.148 254.4)
XYZxyz(16.7403, 16.2449, 54.4671)
Luminance0.1625 (WCAG relative)
Temperaturecool
Familycyan

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2871C4 #C47B28
analogous
#28BFC4 #2871C4 #2D28C4
triadic
#2871C4 #C42871 #71C428
tetradic
#2871C4 #C428BF #C47B28 #28C42D
square
#2871C4 #C428BF #C47B28 #28C42D
split-complementary
#2871C4 #C42D28 #BFC428
monochromatic
#13365E #1E5491 #2871C4 #4E90DB #81B0E5

Accessibility & contrast

On white

4.94
#2871C4 on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

4.25
#2871C4 on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #2871C4
4.94:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2871C4#FFFFFF#000000##FFFFFF
##2871C41.004.944.254.94
#FFFFFF4.941.0021.001.00
#0000004.2521.001.0021.00
##FFFFFF4.941.0021.001.00

Color blindness preview

Protanopia (red-blind)
#4878C7
Deuteranopia (green-blind)
#2B6AC2
Tritanopia (blue-blind)
#008591
Achromatopsia (no color)
#707070

Design tokens & code

CSS
--color: #2871c4;
/* rgb */ color: rgb(40, 113, 196);
/* oklch */ color: oklch(54.7% 0.148 254.4);
Tailwind
colors: {
  custom: {
    50: '#7a99d6',
    500: '#2871c4',
    950: '#000000',
  },
}
SCSS
$custom: #2871c4;
$custom-light: #7a99d6;
$custom-dark: #000000;
JSON
{
  "hex": "#2871c4",
  "rgb": {
    "r": 40,
    "g": 113,
    "b": 196
  },
  "hsl": {
    "h": 211.923,
    "s": 66.102,
    "l": 46.275
  },
  "oklch": {
    "l": 0.54734,
    "c": 0.14756,
    "h": 254.4
  },
  "luminance": 0.16247
}

Semantic roles & 50–950 ramp

primary
#2871C4
secondary
#CEA77A
accent
#993FE9
background
#F8F9FD
surface
#EFF2FA
border
#CACCD3
text
#0B0D14
muted
#7C7E83

Preview Lab

Preview with #2871C4

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

Preview Lab → · Contrast checker → · Palette generator →

#2871C4 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva