#6040CB#6040CB

#6040CB is a mid, highly saturated violet. Relative luminance 0.105; OKLCH L 49.2% C 0.203 H 287.0°. Best body text is #FFFFFF at 6.79:1 contrast (WCAG AA passes).

Color values

HEX#6040CB
RGBrgb(96, 64, 203)
HSLhsl(254, 57%, 52%)
HSVhsv(254, 68%, 80%)
CMYKcmyk(52.7%, 68.5%, 0%, 20.4%)
CIE-LABlab(38.66, 48.47, -67.50)
CIE-LCHlch(38.66, 83.10, 305.68°)
OKLaboklab(49.23% 0.0592 -0.1939)
OKLCHoklch(49.23% 0.203 287)
XYZxyz(17.4336, 10.4645, 57.5896)
Luminance0.1047 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#6040CB #ABCB40
analogous
#4065CB #6040CB #A640CB
triadic
#6040CB #CB6040 #40CB60
tetradic
#6040CB #CB4065 #ABCB40 #40CBA6
square
#6040CB #CB4065 #ABCB40 #40CBA6
split-complementary
#6040CB #CBA640 #65CB40
monochromatic
#321F72 #472CA2 #6040CB #8870D8 #B0A0E5

Accessibility & contrast

On white

6.79
#6040CB on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

3.09
#6040CB on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #6040CB
6.79:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##6040CB#FFFFFF#000000##FFFFFF
##6040CB1.006.793.096.79
#FFFFFF6.791.0021.001.00
#0000003.0921.001.0021.00
##FFFFFF6.791.0021.001.00

Color blindness preview

Protanopia (red-blind)
#005ECF
Deuteranopia (green-blind)
#0057C8
Tritanopia (blue-blind)
#356480
Achromatopsia (no color)
#5B5B5B

Design tokens & code

CSS
--color: #6040cb;
/* rgb */ color: rgb(96, 64, 203);
/* oklch */ color: oklch(49.2% 0.203 287.0);
Tailwind
colors: {
  custom: {
    50: '#9777dc',
    500: '#6040cb',
    950: '#000000',
  },
}
SCSS
$custom: #6040cb;
$custom-light: #9777dc;
$custom-dark: #000000;
JSON
{
  "hex": "#6040cb",
  "rgb": {
    "r": 96,
    "g": 64,
    "b": 203
  },
  "hsl": {
    "h": 253.813,
    "s": 57.202,
    "l": 52.353
  },
  "oklch": {
    "l": 0.49229,
    "c": 0.20274,
    "h": 287
  },
  "luminance": 0.10465
}

Semantic roles & 50–950 ramp

primary
#6040CB
secondary
#C4D295
accent
#E047BD
background
#F9F7FD
surface
#F2EDFB
border
#CCC8D4
text
#0F0915
muted
#7E7B83

Preview Lab

Preview with #6040CB

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

Preview Lab → · Contrast checker → · Palette generator →

#6040CB Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva