#6040C2#6040C2

#6040C2 is a mid, vivid violet. Relative luminance 0.100; OKLCH L 48.5% C 0.192 H 288.4°. Best body text is #FFFFFF at 6.98:1 contrast (WCAG AA passes).

Color values

HEX#6040C2
RGBrgb(96, 64, 194)
HSLhsl(255, 52%, 51%)
HSVhsv(255, 67%, 76%)
CMYKcmyk(50.5%, 67%, 0%, 23.9%)
CIE-LABlab(37.93, 45.86, -63.46)
CIE-LCHlch(37.93, 78.30, 305.86°)
OKLaboklab(48.47% 0.0606 -0.182)
OKLCHoklch(48.47% 0.192 288.4)
XYZxyz(16.3920, 10.0479, 52.1042)
Luminance0.1005 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#6040C2 #A2C240
analogous
#4061C2 #6040C2 #A140C2
triadic
#6040C2 #C26040 #40C260
tetradic
#6040C2 #C24061 #A2C240 #40C2A1
square
#6040C2 #C24061 #A2C240 #40C2A1
split-complementary
#6040C2 #C2A140 #61C240
monochromatic
#322167 #493095 #6040C2 #876ED1 #AD9DE0

Accessibility & contrast

On white

6.98
#6040C2 on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

3.01
#6040C2 on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #6040C2
6.98:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##6040C2#FFFFFF#000000##FFFFFF
##6040C21.006.983.016.98
#FFFFFF6.981.0021.001.00
#0000003.0121.001.0021.00
##FFFFFF6.981.0021.001.00

Color blindness preview

Protanopia (red-blind)
#005CC6
Deuteranopia (green-blind)
#0056BF
Tritanopia (blue-blind)
#3D607C
Achromatopsia (no color)
#595959

Design tokens & code

CSS
--color: #6040c2;
/* rgb */ color: rgb(96, 64, 194);
/* oklch */ color: oklch(48.5% 0.192 288.4);
Tailwind
colors: {
  custom: {
    50: '#9677d5',
    500: '#6040c2',
    950: '#000000',
  },
}
SCSS
$custom: #6040c2;
$custom-light: #9677d5;
$custom-dark: #000000;
JSON
{
  "hex": "#6040c2",
  "rgb": {
    "r": 96,
    "g": 64,
    "b": 194
  },
  "hsl": {
    "h": 254.769,
    "s": 51.587,
    "l": 50.588
  },
  "oklch": {
    "l": 0.48474,
    "c": 0.19186,
    "h": 288.4
  },
  "luminance": 0.10049
}

Semantic roles & 50–950 ramp

primary
#6040C2
secondary
#BECC92
accent
#DB4DB8
background
#F9F7FD
surface
#F2EDFA
border
#CCC8D3
text
#0E0914
muted
#7E7B83

Preview Lab

Preview with #6040C2

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

Preview Lab → · Contrast checker → · Palette generator →

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