#512BAF#512BAF

#512BAF is a dark, vivid violet. Relative luminance 0.066; OKLCH L 42.5% C 0.194 H 288.4°. Best body text is #FFFFFF at 9.07:1 contrast (WCAG AA passes).

Color values

HEX#512BAF
RGBrgb(81, 43, 175)
HSLhsl(257, 61%, 43%)
HSVhsv(257, 75%, 69%)
CMYKcmyk(53.7%, 75.4%, 0%, 31.4%)
CIE-LABlab(30.81, 49.01, -63.93)
CIE-LCHlch(30.81, 80.56, 307.47°)
OKLaboklab(42.55% 0.0611 -0.1838)
OKLCHoklch(42.55% 0.194 288.4)
XYZxyz(11.9928, 6.5716, 41.1857)
Luminance0.0657 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#512BAF #89AF2B
analogous
#2B47AF #512BAF #932BAF
triadic
#512BAF #AF512B #2BAF51
tetradic
#512BAF #AF2B47 #89AF2B #2BAF93
square
#512BAF #AF2B47 #89AF2B #2BAF93
split-complementary
#512BAF #AF932B #47AF2B
monochromatic
#24134D #3A1F7E #512BAF #6E46D1 #9477DE

Accessibility & contrast

On white

9.07
#512BAF on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.31
#512BAF on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #512BAF
9.07:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##512BAF#FFFFFF#000000##FFFFFF
##512BAF1.009.072.319.07
#FFFFFF9.071.0021.001.00
#0000002.3121.001.0021.00
##FFFFFF9.071.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004BB3
Deuteranopia (green-blind)
#0045AD
Tritanopia (blue-blind)
#2C506B
Achromatopsia (no color)
#494949

Design tokens & code

CSS
--color: #512baf;
/* rgb */ color: rgb(81, 43, 175);
/* oklch */ color: oklch(42.5% 0.194 288.4);
Tailwind
colors: {
  custom: {
    50: '#8c69c8',
    500: '#512baf',
    950: '#000000',
  },
}
SCSS
$custom: #512baf;
$custom-light: #8c69c8;
$custom-dark: #000000;
JSON
{
  "hex": "#512baf",
  "rgb": {
    "r": 81,
    "g": 43,
    "b": 175
  },
  "hsl": {
    "h": 257.273,
    "s": 60.55,
    "l": 42.745
  },
  "oklch": {
    "l": 0.42546,
    "c": 0.19374,
    "h": 288.4
  },
  "luminance": 0.06572
}

Semantic roles & 50–950 ramp

primary
#512BAF
secondary
#ADC570
accent
#E444B6
background
#F9F6FC
surface
#F1EBF8
border
#CBC6D1
text
#0D0613
muted
#7E7A82

Preview Lab

Preview with #512BAF

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

Preview Lab → · Contrast checker → · Palette generator →

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