Skip to content

#2802cf

a dark, electric blue · cool · closest name: Medium Blue

RGB
40, 2, 207
HSL
251°, 98%, 41%
CMYK
81, 99, 0, 19
Luminance
0.0500

At a glance

Every number on this page in one read: what #2802cf is made of, how bright it looks, and which way it leans.

Hex
#2802cf
Hue
251°
blue
Saturation
98%
electric
Lightness
41%
dark
Brightness
81%
HSV value
Perceived
29%
weighted brightness
Luminance
0.0500
WCAG relative
Temperature
Cool
77/100 cool
Color family
Blue
Tone
Electric
Best ink
White
10.50:1
Closest name
Medium Blue
ΔE2000 1.5
Where it sits
Hue251° of 360°
Saturation98%
Lightness41%
Temperature
Warm ← → Cool77% cool

Reads cool. Warm and cool siblings keep the same lightness, so you can swap one in without redoing your contrast maths.

Every format

HEX#2802cf
RGBrgb(40, 2, 207)
HSLhsl(251, 98%, 41%)
CMYKcmyk(81%, 99%, 0%, 19%)
LABlab(26.7 67.7 -89.7)
LCHlch(26.7 112.4 307.1)
OKLCHoklch(0.400 0.259 270.8)
Decimal2622159
Display P3color(display-p3 0.157 0.008 0.812)

Copy-ready code

/* CSS */
color: #2802cf;
background-color: #2802cf;
/* Tailwind (arbitrary) */
class="text-[#2802cf] bg-[#2802cf]"
/* SCSS */
$brand: #2802cf;
/* SwiftUI */
Color(red: 0.157, green: 0.008, blue: 0.812)
/* Android */
Color.parseColor("#2802cf")
/* Flutter */
Color(0xFF2802CF)
/* Python / OpenCV (BGR) */
(207, 2, 40)

Best text color

Only one of black and white can be right. This is the one, with the number that proves it.

Readable at a glance#ffffff on #2802cf · 10.50:1
Use #ffffffAAA at every size.
Aa
White text · 10.50:1 · recommended
AA pass · AA large pass · AAA pass
Aa
Black text · 2.00:1
AA fail · AA large fail · AAA fail
Reading the other direction: #2802cf as text scores 10.50:1 on white and 2.00:1 on black.

Accessibility — WCAG contrast

Aa
#2802cf on white: 10.50:1
AA ✓ pass · AA-large · AAA
Aa
#2802cf on black: 2.00:1
AA ✗ fail · AA-large · AAA
true color
protanopia · #0048D4
deuteranopia · #0035CC
tritanopia · #005579

Color scale — 50 to 950

A Tailwind-shaped ramp built around this exact hex. #2802cf is pinned to step 700; the rest hold its hue and let saturation ease off at the extremes so the pale end never turns neon.

#F3F1FD
#E8E3FC
#CBC1FB
#A490FE
#7758FD
#4921FD
#2F02F2
#2802cf
#1F02A2
#1A0674
#110449
Base = 700Lightest = 50 · #F3F1FDDarkest = 950 · #110449
:root {
  --brand-50: #F3F1FD;
  --brand-100: #E8E3FC;
  --brand-200: #CBC1FB;
  --brand-300: #A490FE;
  --brand-400: #7758FD;
  --brand-500: #4921FD;
  --brand-600: #2F02F2;
  --brand-700: #2802cf;
  --brand-800: #1F02A2;
  --brand-900: #1A0674;
  --brand-950: #110449;
  --brand: #2802cf;
  --brand-ink: #ffffff;
}

Colors that work with #2802cf

Not a palette — a role sheet. Each swatch answers one question you will hit while building the component.

Text on it#ffffff
White wins here
Surface#F5F4FA
Tinted page background
Border#C8C0ED
Hairlines and dividers
Muted text#594B9B
Captions on the surface
Accent#CCBF00
Second voice, not a rival
Dark variant#18017E
Hover, pressed, headers
Light variant#EAE6FF
Selected rows, tints
Dark surface#171424
Dark-mode background
Light mode
Everything in its place

Surface, border, heading and body all derive from this one hue, so the screen stays coherent without a second palette.

Primary actionSecondaryBadge
Dark mode
Same hue, inverted

Lightness flips, hue holds. The accent stays the anchor in both themes.

Primary actionSecondaryAccent

How to use #2802cf

Derived from its contrast, chroma and lightness — not from taste.

Works well for
  • Body text and links on white
  • Primary buttons and calls to action
  • Focus rings, active and selected states
  • Headers, footers and dark-mode surfaces
  • Brand accents, badges and data highlights
Use with care
  • Text on black or near-black surfaces
  • Full-page backgrounds — tiring over long sessions
  • Black text placed on it
  • Pairing with a same-lightness hue — edges vibrate

Similar colors

One move away from this hex in each direction. Every swatch is its own page.

Color relationships

The wheel positions with their names attached, so you can grab the one you actually need.

Complementary#A9CF02
Analogous left#0243CF
Analogous right#8E02CF
Split-complement 1#CF8E02
Split-complement 2#43CF02
Triadic 1#CF2802
Triadic 2#02CF28
Tetradic#CF0243

RGB percentages

Red15.7%
Green0.8%
Blue81.2%

CMYK percentages

Cyan80.7%
Magenta99.0%
Yellow0.0%
Key (black)18.8%

Color previews

#2802cf text on a black background

contrast 2.00:1

Card sample

#2802cf text on a white background

contrast 10.50:1

Card sample

CSS3 live lab

Text font color

The quick brown fox

color: #2802cf;
Background color
Panel with #2802cf background
background-color: #2802cf;
Text shadow — hex

Glowing headline

text-shadow: 2px 2px 8px #2802cf;
Text shadow — RGB

Soft neon halo

text-shadow: 0 0 14px rgba(40, 2, 207, 0.45);
Div box shadow
Elevated card
box-shadow: 0 12px 32px -8px rgba(40, 2, 207, 0.45);
Border & gradient
Gradient panel
border: 3px solid #2802cf;
background: linear-gradient(135deg, #2802cf, #B102CF);

Monochromatic scale

Palettes built from #2802cf

Shades — darker

Tints — lighter

Color harmonies

Nearest named colors

Ranked with CIEDE2000 across all 139 CSS keywords. Under ΔE 2 the eye stops telling them apart; over ΔE 10 they are plainly different colors.

#2802cf in the real world

Where a color in this family tends to land, and the interface roles it is usually asked to play.

Industries
TechnologyFinanceHealthcareEnterprise SaaS
Common UI roles
ButtonsLinksFocus statesCharts
Print note

Sits outside most CMYK gamuts — expect a duller press result, or specify a spot ink.

#2802cf, answered

What color is #2802cf?

#2802cf is a dark electric blue, closest to Medium Blue (ΔE2000 1.5). It sits at 251° on the hue wheel with 98% saturation and 41% lightness, which reads as cool.

What is the RGB value of #2802cf?

rgb(40, 2, 207) — 40 red, 2 green and 207 blue out of 255, or 15.7% / 0.8% / 81.2% by channel.

Is #2802cf a light or a dark color?

It is a dark color. Relative luminance is 0.0500 and perceived brightness is 29%, so white text on it reaches 10.50:1.

Should I use black or white text on #2802cf?

White. It scores 10.50:1 against #2802cf, versus 2.00:1 for black — AAA at any size.

What is the complementary color of #2802cf?

#A9CF02 sits directly opposite on the wheel. Softer options are the split-complements #CF8E02 and #43CF02, which give the same contrast with far less vibration.

What colors go well with #2802cf?

For interface work: #F5F4FA as the surface, #C8C0ED for borders, #594B9B for secondary text, #CCBF00 as an accent and #18017E for hover and pressed states. For a palette, the analogous pair #0243CF and #8E02CF stays calm, while #A9CF02 is the loudest partner.

What is #2802cf in CMYK for printing?

cmyk(81%, 99%, 0%, 19%). This is a screen-to-ink approximation — a color this saturated sits outside most CMYK gamuts and will print duller than it looks here.

Is #2802cf warm or cool?

Cool — it scores 77 on a scale where 0 is the warmest orange and 100 the coolest azure. Nudged warmer it becomes #7302CF; nudged cooler, #001FD1.

Work with #2802cf in the Color Lab