#4042CF#4042CF

#4042CF is a mid, highly saturated blue. Relative luminance 0.095; OKLCH L 47.4% C 0.211 H 274.2°. Best body text is #FFFFFF at 7.25:1 contrast (WCAG AA passes).

Color values

HEX#4042CF
RGBrgb(64, 66, 207)
HSLhsl(239, 60%, 53%)
HSVhsv(239, 69%, 81%)
CMYKcmyk(69.1%, 68.1%, 0%, 18.8%)
CIE-LABlab(36.91, 44.05, -72.78)
CIE-LCHlch(36.91, 85.08, 301.18°)
OKLaboklab(47.45% 0.0156 -0.2103)
OKLCHoklch(47.45% 0.211 274.2)
XYZxyz(15.3213, 9.4900, 60.0437)
Luminance0.0949 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#4042CF #CFCD40
analogous
#4089CF #4042CF #8540CF
triadic
#4042CF #CF4042 #42CF40
tetradic
#4042CF #CF4089 #CFCD40 #40CF85
square
#4042CF #CF4089 #CFCD40 #40CF85
split-complementary
#4042CF #CF8540 #89CF40
monochromatic
#1E1F77 #2A2CA8 #4042CF #7172DB #A2A3E8

Accessibility & contrast

On white

7.25
#4042CF on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.90
#4042CF on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #4042CF
7.25:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##4042CF#FFFFFF#000000##FFFFFF
##4042CF1.007.252.907.25
#FFFFFF7.251.0021.001.00
#0000002.9021.001.0021.00
##FFFFFF7.251.0021.001.00

Color blindness preview

Protanopia (red-blind)
#005DD3
Deuteranopia (green-blind)
#0050CC
Tritanopia (blue-blind)
#006883
Achromatopsia (no color)
#575757

Design tokens & code

CSS
--color: #4042cf;
/* rgb */ color: rgb(64, 66, 207);
/* oklch */ color: oklch(47.4% 0.211 274.2);
Tailwind
colors: {
  custom: {
    50: '#8877df',
    500: '#4042cf',
    950: '#000000',
  },
}
SCSS
$custom: #4042cf;
$custom-light: #8877df;
$custom-dark: #000000;
JSON
{
  "hex": "#4042cf",
  "rgb": {
    "r": 64,
    "g": 66,
    "b": 207
  },
  "hsl": {
    "h": 239.161,
    "s": 59.833,
    "l": 53.137
  },
  "oklch": {
    "l": 0.47446,
    "c": 0.21089,
    "h": 274.2
  },
  "luminance": 0.09491
}

Semantic roles & 50–950 ramp

primary
#4042CF
secondary
#D4D397
accent
#E145E3
background
#F9F7FD
surface
#F1EDFB
border
#CBC8D4
text
#0D0915
muted
#7E7B83

Preview Lab

Preview with #4042CF

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

Preview Lab → · Contrast checker → · Palette generator →

#4042CF Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva