#7040D4#7040D4

#7040D4 is a mid, highly saturated violet. Relative luminance 0.119; OKLCH L 51.5% C 0.213 H 292.1°. Best body text is #FFFFFF at 6.23:1 contrast (WCAG AA passes).

Color values

HEX#7040D4
RGBrgb(112, 64, 212)
HSLhsl(259, 63%, 54%)
HSVhsv(259, 70%, 83%)
CMYKcmyk(47.2%, 69.8%, 0%, 16.9%)
CIE-LABlab(41.00, 53.66, -68.81)
CIE-LCHlch(41.00, 87.26, 307.94°)
OKLaboklab(51.5% 0.08 -0.1972)
OKLCHoklch(51.5% 0.213 292.1)
XYZxyz(20.3958, 11.8643, 63.4900)
Luminance0.1187 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#7040D4 #A4D440
analogous
#405AD4 #7040D4 #BA40D4
triadic
#7040D4 #D47040 #40D470
tetradic
#7040D4 #D4405A #A4D440 #40D4BA
square
#7040D4 #D4405A #A4D440 #40D4BA
split-complementary
#7040D4 #D4BA40 #5AD440
monochromatic
#3C1C7D #5427AF #7040D4 #9572DF #BBA4EA

Accessibility & contrast

On white

6.23
#7040D4 on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

3.37
#7040D4 on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #7040D4
6.23:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##7040D4#FFFFFF#000000##FFFFFF
##7040D41.006.233.376.23
#FFFFFF6.231.0021.001.00
#0000003.3721.001.0021.00
##FFFFFF6.231.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0063D8
Deuteranopia (green-blind)
#005ED1
Tritanopia (blue-blind)
#516685
Achromatopsia (no color)
#616161

Design tokens & code

CSS
--color: #7040d4;
/* rgb */ color: rgb(112, 64, 212);
/* oklch */ color: oklch(51.5% 0.213 292.1);
Tailwind
colors: {
  custom: {
    50: '#a179e2',
    500: '#7040d4',
    950: '#000000',
  },
}
SCSS
$custom: #7040d4;
$custom-light: #a179e2;
$custom-dark: #000000;
JSON
{
  "hex": "#7040d4",
  "rgb": {
    "r": 112,
    "g": 64,
    "b": 212
  },
  "hsl": {
    "h": 259.459,
    "s": 63.248,
    "l": 54.118
  },
  "oklch": {
    "l": 0.51503,
    "c": 0.21286,
    "h": 292.1
  },
  "luminance": 0.11865
}

Semantic roles & 50–950 ramp

primary
#7040D4
secondary
#C3D798
accent
#E642B1
background
#FAF7FE
surface
#F4EEFC
border
#CEC9D5
text
#100915
muted
#7F7B84

Preview Lab

Preview with #7040D4

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

Preview Lab → · Contrast checker → · Palette generator →

#7040D4 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva