#3040B5#3040B5

#3040B5 is a dark, vivid blue. Relative luminance 0.076; OKLCH L 43.8% C 0.184 H 270.6°. Best body text is #FFFFFF at 8.31:1 contrast (WCAG AA passes).

Color values

HEX#3040B5
RGBrgb(48, 64, 181)
HSLhsl(233, 58%, 45%)
HSVhsv(233, 73%, 71%)
CMYKcmyk(73.5%, 64.6%, 0%, 29%)
CIE-LABlab(33.20, 34.44, -63.68)
CIE-LCHlch(33.20, 72.40, 298.40°)
OKLaboklab(43.79% 0.0018 -0.1841)
OKLCHoklch(43.79% 0.184 270.6)
XYZxyz(11.3900, 7.6302, 44.5796)
Luminance0.0763 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#3040B5 #B5A530
analogous
#3083B5 #3040B5 #6330B5
triadic
#3040B5 #B53040 #40B530
tetradic
#3040B5 #B53083 #B5A530 #30B563
square
#3040B5 #B53083 #B5A530 #30B563
split-complementary
#3040B5 #B56330 #83B530
monochromatic
#161E54 #232F85 #3040B5 #5161D1 #828DDE

Accessibility & contrast

On white

8.31
#3040B5 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.53
#3040B5 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #3040B5
8.31:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##3040B5#FFFFFF#000000##FFFFFF
##3040B51.008.312.538.31
#FFFFFF8.311.0021.001.00
#0000002.5321.001.0021.00
##FFFFFF8.311.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0054B9
Deuteranopia (green-blind)
#0048B3
Tritanopia (blue-blind)
#005F74
Achromatopsia (no color)
#4E4E4E

Design tokens & code

CSS
--color: #3040b5;
/* rgb */ color: rgb(48, 64, 181);
/* oklch */ color: oklch(43.8% 0.184 270.6);
Tailwind
colors: {
  custom: {
    50: '#7c75cc',
    500: '#3040b5',
    950: '#000000',
  },
}
SCSS
$custom: #3040b5;
$custom-light: #7c75cc;
$custom-dark: #000000;
JSON
{
  "hex": "#3040b5",
  "rgb": {
    "r": 48,
    "g": 64,
    "b": 181
  },
  "hsl": {
    "h": 232.782,
    "s": 58.079,
    "l": 44.902
  },
  "oklch": {
    "l": 0.43788,
    "c": 0.18408,
    "h": 270.6
  },
  "luminance": 0.07631
}

Semantic roles & 50–950 ramp

primary
#3040B5
secondary
#C7BE7A
accent
#CF46E1
background
#F8F7FC
surface
#EFEDF9
border
#CAC8D2
text
#0B0813
muted
#7C7B82

Preview Lab

Preview with #3040B5

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

Preview Lab → · Contrast checker → · Palette generator →

#3040B5 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva