Skip to content

#2a5df0

a balanced, electric blue · cool · closest name: royalblue

RGB
42, 93, 240
HSL
225°, 87%, 55%
CMYK
83, 61, 0, 6
Luminance
0.1461

Every format

HEX#2a5df0
RGBrgb(42, 93, 240)
HSLhsl(225, 87%, 55%)
CMYKcmyk(83%, 61%, 0%, 6%)
LABlab(45.1 37.0 -78.2)
LCHlch(45.1 86.5 295.3)
OKLCHoklch(0.541 0.227 264.8)

Copy-ready code

/* CSS */
color: #2a5df0;
background-color: #2a5df0;
/* Tailwind (arbitrary) */
class="text-[#2a5df0] bg-[#2a5df0]"
/* SCSS */
$brand: #2a5df0;
/* SwiftUI */
Color(red: 0.165, green: 0.365, blue: 0.941)
/* Android */
Color.parseColor("#2a5df0")

Accessibility — WCAG contrast

Aa
#2a5df0 on white: 5.35:1
AA ✓ pass · AA-large · AAA
Aa
#2a5df0 on black: 3.92:1
AA ✗ fail · AA-large · AAA
true color
protanopia
deuteranopia
tritanopia

RGB percentages

Red16.5%
Green36.5%
Blue94.1%

CMYK percentages

Cyan82.5%
Magenta61.2%
Yellow0.0%
Key (black)5.9%

Color previews

#2a5df0 text on a black background

contrast 3.92:1

Card sample

#2a5df0 text on a white background

contrast 5.35:1

Card sample

CSS3 live lab

Text font color

The quick brown fox

color: #2a5df0;
Background color
Panel with #2a5df0 background
background-color: #2a5df0;
Text shadow — hex

Glowing headline

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

Soft neon halo

text-shadow: 0 0 14px rgba(42, 93, 240, 0.45);
Div box shadow
Elevated card
box-shadow: 0 12px 32px -8px rgba(42, 93, 240, 0.45);
Border & gradient
Gradient panel
border: 3px solid #2a5df0;
background: linear-gradient(135deg, #2a5df0, #7B2AF0);

Monochromatic scale

Palettes built from #2a5df0

Shades — darker

Tints — lighter

Hue & tone neighbors

Color harmonies

Nearest named colors

Work with #2a5df0 in the Color Lab