#512FC4#512FC4

#512FC4 is a mid, highly saturated violet. Relative luminance 0.078; OKLCH L 45.0% C 0.214 H 284.3°. Best body text is #FFFFFF at 8.22:1 contrast (WCAG AA passes).

Color values

HEX#512FC4
RGBrgb(81, 47, 196)
HSLhsl(254, 61%, 48%)
HSVhsv(254, 76%, 77%)
CMYKcmyk(58.7%, 76%, 0%, 23.1%)
CIE-LABlab(33.49, 53.04, -71.95)
CIE-LCHlch(33.49, 89.39, 306.40°)
OKLaboklab(45.03% 0.0527 -0.2073)
OKLCHoklch(45.03% 0.214 284.3)
XYZxyz(14.3706, 7.7670, 52.9558)
Luminance0.0777 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#512FC4 #A2C42F
analogous
#2F58C4 #512FC4 #9B2FC4
triadic
#512FC4 #C4512F #2FC451
tetradic
#512FC4 #C42F58 #A2C42F #2FC49B
square
#512FC4 #C42F58 #A2C42F #2FC49B
split-complementary
#512FC4 #C49B2F #58C42F
monochromatic
#281761 #3D2393 #512FC4 #7659D7 #9F8AE3

Accessibility & contrast

On white

8.22
#512FC4 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.55
#512FC4 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #512FC4
8.22:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##512FC4#FFFFFF#000000##FFFFFF
##512FC41.008.222.558.22
#FFFFFF8.221.0021.001.00
#0000002.5521.001.0021.00
##FFFFFF8.221.0021.001.00

Color blindness preview

Protanopia (red-blind)
#0053C8
Deuteranopia (green-blind)
#004AC1
Tritanopia (blue-blind)
#085A78
Achromatopsia (no color)
#4F4F4F

Design tokens & code

CSS
--color: #512fc4;
/* rgb */ color: rgb(81, 47, 196);
/* oklch */ color: oklch(45.0% 0.214 284.3);
Tailwind
colors: {
  custom: {
    50: '#8f6cd7',
    500: '#512fc4',
    950: '#000000',
  },
}
SCSS
$custom: #512fc4;
$custom-light: #8f6cd7;
$custom-dark: #000000;
JSON
{
  "hex": "#512fc4",
  "rgb": {
    "r": 81,
    "g": 47,
    "b": 196
  },
  "hsl": {
    "h": 253.691,
    "s": 61.317,
    "l": 47.647
  },
  "oklch": {
    "l": 0.45032,
    "c": 0.21392,
    "h": 284.3
  },
  "luminance": 0.07768
}

Semantic roles & 50–950 ramp

primary
#512FC4
secondary
#BCCD82
accent
#E443C0
background
#F9F6FD
surface
#F2ECFA
border
#CCC7D3
text
#0E0715
muted
#7E7A83

Preview Lab

Preview with #512FC4

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

Preview Lab → · Contrast checker → · Palette generator →

#512FC4 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva