#6840CB#6840CB

#6840CB is a mid, highly saturated violet. Relative luminance 0.109; OKLCH L 50.0% C 0.202 H 290.3°. Best body text is #FFFFFF at 6.59:1 contrast (WCAG AA passes).

Color values

HEX#6840CB
RGBrgb(104, 64, 203)
HSLhsl(257, 57%, 52%)
HSVhsv(257, 68%, 80%)
CMYKcmyk(48.8%, 68.5%, 0%, 20.4%)
CIE-LABlab(39.45, 49.82, -66.18)
CIE-LCHlch(39.45, 82.84, 306.97°)
OKLaboklab(49.98% 0.0704 -0.1898)
OKLCHoklch(49.98% 0.202 290.3)
XYZxyz(18.3187, 10.9209, 57.6311)
Luminance0.1092 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#6840CB #A3CB40
analogous
#405ECB #6840CB #AD40CB
triadic
#6840CB #CB6840 #40CB68
tetradic
#6840CB #CB405E #A3CB40 #40CBAD
square
#6840CB #CB405E #A3CB40 #40CBAD
split-complementary
#6840CB #CBAD40 #5ECB40
monochromatic
#371F72 #4E2CA2 #6840CB #8E70D8 #B4A0E5

Accessibility & contrast

On white

6.59
#6840CB on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

3.18
#6840CB on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #6840CB
6.59:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##6840CB#FFFFFF#000000##FFFFFF
##6840CB1.006.593.186.59
#FFFFFF6.591.0021.001.00
#0000003.1821.001.0021.00
##FFFFFF6.591.0021.001.00

Color blindness preview

Protanopia (red-blind)
#005FCF
Deuteranopia (green-blind)
#005AC8
Tritanopia (blue-blind)
#476380
Achromatopsia (no color)
#5D5D5D

Design tokens & code

CSS
--color: #6840cb;
/* rgb */ color: rgb(104, 64, 203);
/* oklch */ color: oklch(50.0% 0.202 290.3);
Tailwind
colors: {
  custom: {
    50: '#9c78dc',
    500: '#6840cb',
    950: '#000000',
  },
}
SCSS
$custom: #6840cb;
$custom-light: #9c78dc;
$custom-dark: #000000;
JSON
{
  "hex": "#6840cb",
  "rgb": {
    "r": 104,
    "g": 64,
    "b": 203
  },
  "hsl": {
    "h": 257.266,
    "s": 57.202,
    "l": 52.353
  },
  "oklch": {
    "l": 0.49976,
    "c": 0.20242,
    "h": 290.3
  },
  "luminance": 0.10922
}

Semantic roles & 50–950 ramp

primary
#6840CB
secondary
#C0D295
accent
#E047B4
background
#FAF7FD
surface
#F4EDFB
border
#CEC8D4
text
#0F0915
muted
#7F7B83

Preview Lab

Preview with #6840CB

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

Preview Lab → · Contrast checker → · Palette generator →

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