#7040B2#7040B2

#7040B2 is a mid, vivid violet. Relative luminance 0.103; OKLCH L 48.8% C 0.173 H 299.2°. Best body text is #FFFFFF at 6.85:1 contrast (WCAG AA passes).

Color values

HEX#7040B2
RGBrgb(112, 64, 178)
HSLhsl(265, 47%, 47%)
HSVhsv(265, 64%, 70%)
CMYKcmyk(37.1%, 64%, 0%, 30.2%)
CIE-LABlab(38.42, 44.63, -53.17)
CIE-LCHlch(38.42, 69.42, 310.01°)
OKLaboklab(48.84% 0.0847 -0.1513)
OKLCHoklch(48.84% 0.173 299.2)
XYZxyz(16.5494, 10.3257, 43.2320)
Luminance0.1033 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#7040B2 #82B240
analogous
#4049B2 #7040B2 #A940B2
triadic
#7040B2 #B27040 #40B270
tetradic
#7040B2 #B24049 #82B240 #40B2A9
square
#7040B2 #B24049 #82B240 #40B2A9
split-complementary
#7040B2 #B2A940 #49B240
monochromatic
#372058 #543085 #7040B2 #9067C8 #B194D8

Accessibility & contrast

On white

6.85
#7040B2 on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

3.07
#7040B2 on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #7040B2
6.85:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##7040B2#FFFFFF#000000##FFFFFF
##7040B21.006.853.076.85
#FFFFFF6.851.0021.001.00
#0000003.0721.001.0021.00
##FFFFFF6.851.0021.001.00

Color blindness preview

Protanopia (red-blind)
#005AB6
Deuteranopia (green-blind)
#0759B0
Tritanopia (blue-blind)
#615973
Achromatopsia (no color)
#5A5A5A

Design tokens & code

CSS
--color: #7040b2;
/* rgb */ color: rgb(112, 64, 178);
/* oklch */ color: oklch(48.8% 0.173 299.2);
Tailwind
colors: {
  custom: {
    50: '#9e78ca',
    500: '#7040b2',
    950: '#000000',
  },
}
SCSS
$custom: #7040b2;
$custom-light: #9e78ca;
$custom-dark: #000000;
JSON
{
  "hex": "#7040b2",
  "rgb": {
    "r": 112,
    "g": 64,
    "b": 178
  },
  "hsl": {
    "h": 265.263,
    "s": 47.107,
    "l": 47.451
  },
  "oklch": {
    "l": 0.48844,
    "c": 0.17336,
    "h": 299.2
  },
  "luminance": 0.10326
}

Semantic roles & 50–950 ramp

primary
#7040B2
secondary
#ABC48A
accent
#D7519E
background
#FAF7FC
surface
#F3EDF8
border
#CDC8D1
text
#0F0913
muted
#7F7B82

Preview Lab

Preview with #7040B2

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

Preview Lab → · Contrast checker → · Palette generator →

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