#2540B2#2540B2
#2540B2 is a dark, vivid blue. Relative luminance 0.073; OKLCH L 43.0% C 0.183 H 267.4°. Best body text is #FFFFFF at 8.55:1 contrast (WCAG AA passes).
Color values
| HEX | #2540B2 |
|---|---|
| RGB | rgb(37, 64, 178) |
| HSL | hsl(229, 66%, 42%) |
| HSV | hsv(229, 79%, 70%) |
| CMYK | cmyk(79.2%, 64%, 0%, 30.2%) |
| CIE-LAB | lab(32.42, 32.18, -63.20) |
| CIE-LCH | lch(32.42, 70.92, 296.99°) |
| OKLab | oklab(42.99% -0.0083 -0.1829) |
| OKLCH | oklch(42.99% 0.183 267.4) |
| XYZ | xyz(10.6294, 7.2732, 42.9545) |
| Luminance | 0.0727 (WCAG relative) |
| Temperature | cool |
| Family | blue |
Closest named colors
Sapphire (survey)
#2138AB
ΔE00 2.45
Blue Blue
#2242C7
ΔE00 2.82
Cobalt
#0047AB
ΔE00 4.23
Ocean Blue
#4F42B5
ΔE00 5.37
Blue (survey)
#0343DF
ΔE00 5.64
Blueberry
#464196
ΔE00 5.94
Perceptual scales
Shades
Tints
Tones
OKLCH scale
Color harmonies
complementary
#2540B2 #B29725
analogous
#2586B2 #2540B2 #5125B2
triadic
#2540B2 #B22540 #40B225
tetradic
#2540B2 #B22586 #B29725 #25B251
square
#2540B2 #B22586 #B29725 #25B251
split-complementary
#2540B2 #B25125 #86B225
monochromatic
#101C4D #1A2E7F #2540B2 #3D5BD7 #7086E1
Accessibility & contrast
On white
8.55
#2540B2 on #FFFFFF
AA ✓AA large ✓AAA ✓
On black
2.45
#2540B2 on #000000
AA ✗AA large ✗AAA ✗
Best text color
#FFFFFF on #2540B2
8.55:1 — WCAG AA (normal text) passes
Contrast matrix
| fg \ bg | ##2540B2 | #FFFFFF | #000000 | ##FFFFFF |
|---|---|---|---|---|
| ##2540B2 | 1.00 | 8.55 | 2.45 | 8.55 |
| #FFFFFF | 8.55 | 1.00 | 21.00 | 1.00 |
| #000000 | 2.45 | 21.00 | 1.00 | 21.00 |
| ##FFFFFF | 8.55 | 1.00 | 21.00 | 1.00 |
Color blindness preview
Protanopia (red-blind)
#0053B6
Deuteranopia (green-blind)
#0046B0
Tritanopia (blue-blind)
#005E73
Achromatopsia (no color)
#4C4C4C
Design tokens & code
CSS
--color: #2540b2; /* rgb */ color: rgb(37, 64, 178); /* oklch */ color: oklch(43.0% 0.183 267.4);
Tailwind
colors: {
custom: {
50: '#7774ca',
500: '#2540b2',
950: '#000000',
},
}SCSS
$custom: #2540b2; $custom-light: #7774ca; $custom-dark: #000000;
JSON
{
"hex": "#2540b2",
"rgb": {
"r": 37,
"g": 64,
"b": 178
},
"hsl": {
"h": 228.511,
"s": 65.581,
"l": 42.157
},
"oklch": {
"l": 0.42992,
"c": 0.18307,
"h": 267.4
},
"luminance": 0.07274
}Semantic roles & 50–950 ramp
primary
#2540B2
secondary
#C8B66B
accent
#C83FE9
background
#F8F7FC
surface
#EFEDF9
border
#CAC8D2
text
#0A0813
muted
#7C7B82