Skip to content

#511ec3

a dark, vivid violet · cool · closest name: Medium Blue

RGB
81, 30, 195
HSL
259°, 73%, 44%
CMYK
59, 85, 0, 24
Luminance
0.0662

At a glance

Every number on this page in one read: what #511ec3 is made of, how bright it looks, and which way it leans.

Hex
#511ec3
Hue
259°
violet
Saturation
73%
vivid
Lightness
44%
dark
Brightness
76%
HSV value
Perceived
32%
weighted brightness
Luminance
0.0662
WCAG relative
Temperature
Cool
73/100 cool
Color family
Violet
Tone
Vivid
Best ink
White
9.04:1
Closest name
Medium Blue
ΔE2000 5.9
Where it sits
Hue259° of 360°
Saturation73%
Lightness44%
Temperature
Warm ← → Cool73% cool

Reads cool. Warm and cool siblings keep the same lightness, so you can swap one in without redoing your contrast maths.

Every format

HEX#511ec3
RGBrgb(81, 30, 195)
HSLhsl(259, 73%, 44%)
CMYKcmyk(59%, 85%, 0%, 24%)
LABlab(30.9 60.0 -75.6)
LCHlch(30.9 96.5 308.4)
OKLCHoklch(0.432 0.227 286.1)
Decimal5316291
Display P3color(display-p3 0.318 0.118 0.765)

Copy-ready code

/* CSS */
color: #511ec3;
background-color: #511ec3;
/* Tailwind (arbitrary) */
class="text-[#511ec3] bg-[#511ec3]"
/* SCSS */
$brand: #511ec3;
/* SwiftUI */
Color(red: 0.318, green: 0.118, blue: 0.765)
/* Android */
Color.parseColor("#511ec3")
/* Flutter */
Color(0xFF511EC3)
/* Python / OpenCV (BGR) */
(195, 30, 81)

Best text color

Only one of black and white can be right. This is the one, with the number that proves it.

Readable at a glance#ffffff on #511ec3 · 9.04:1
Use #ffffffAAA at every size.
Aa
White text · 9.04:1 · recommended
AA pass · AA large pass · AAA pass
Aa
Black text · 2.32:1
AA fail · AA large fail · AAA fail
Reading the other direction: #511ec3 as text scores 9.04:1 on white and 2.32:1 on black.

Accessibility — WCAG contrast

Aa
#511ec3 on white: 9.04:1
AA ✓ pass · AA-large · AAA
Aa
#511ec3 on black: 2.32:1
AA ✗ fail · AA-large · AAA
true color
protanopia · #004DC7
deuteranopia · #0044C0
tritanopia · #0F5374

Color scale — 50 to 950

A Tailwind-shaped ramp built around this exact hex. #511ec3 is pinned to step 600; the rest hold its hue and let saturation ease off at the extremes so the pale end never turns neon.

#F6F3FC
#ECE7F8
#D6C8F3
#B79EF0
#936DE9
#6F3DE1
#511ec3
#491BB1
#3B168D
#2D1466
#1C0C40
Base = 600Lightest = 50 · #F6F3FCDarkest = 950 · #1C0C40
:root {
  --brand-50: #F6F3FC;
  --brand-100: #ECE7F8;
  --brand-200: #D6C8F3;
  --brand-300: #B79EF0;
  --brand-400: #936DE9;
  --brand-500: #6F3DE1;
  --brand-600: #511ec3;
  --brand-700: #491BB1;
  --brand-800: #3B168D;
  --brand-900: #2D1466;
  --brand-950: #1C0C40;
  --brand: #511ec3;
  --brand-ink: #ffffff;
}

Colors that work with #511ec3

Not a palette — a role sheet. Each swatch answers one question you will hit while building the component.

Text on it#ffffff
White wins here
Surface#F6F4FA
Tinted page background
Border#CEC0ED
Hairlines and dividers
Muted text#634B9B
Captions on the surface
Accent#ABB418
Second voice, not a rival
Dark variant#2E116E
Hover, pressed, headers
Light variant#EFE9FC
Selected rows, tints
Dark surface#191424
Dark-mode background
Light mode
Everything in its place

Surface, border, heading and body all derive from this one hue, so the screen stays coherent without a second palette.

Primary actionSecondaryBadge
Dark mode
Same hue, inverted

Lightness flips, hue holds. The accent stays the anchor in both themes.

Primary actionSecondaryAccent

How to use #511ec3

Derived from its contrast, chroma and lightness — not from taste.

Works well for
  • Body text and links on white
  • Primary buttons and calls to action
  • Focus rings, active and selected states
  • Headers, footers and dark-mode surfaces
  • Brand accents, badges and data highlights
Use with care
  • Text on black or near-black surfaces
  • Full-page backgrounds — tiring over long sessions
  • Black text placed on it
  • Pairing with a same-lightness hue — edges vibrate

Similar colors

One move away from this hex in each direction. Every swatch is its own page.

Color relationships

The wheel positions with their names attached, so you can grab the one you actually need.

Complementary#90C31E
Analogous left#1E3EC3
Analogous right#A31EC3
Split-complement 1#C3A31E
Split-complement 2#3EC31E
Triadic 1#C3511E
Triadic 2#1EC351
Tetradic#C31E3E

RGB percentages

Red31.8%
Green11.8%
Blue76.5%

CMYK percentages

Cyan58.5%
Magenta84.6%
Yellow0.0%
Key (black)23.5%

Color previews

#511ec3 text on a black background

contrast 2.32:1

Card sample

#511ec3 text on a white background

contrast 9.04:1

Card sample

CSS3 live lab

Text font color

The quick brown fox

color: #511ec3;
Background color
Panel with #511ec3 background
background-color: #511ec3;
Text shadow — hex

Glowing headline

text-shadow: 2px 2px 8px #511ec3;
Text shadow — RGB

Soft neon halo

text-shadow: 0 0 14px rgba(81, 30, 195, 0.45);
Div box shadow
Elevated card
box-shadow: 0 12px 32px -8px rgba(81, 30, 195, 0.45);
Border & gradient
Gradient panel
border: 3px solid #511ec3;
background: linear-gradient(135deg, #511ec3, #BF1EC3);

Monochromatic scale

Palettes built from #511ec3

Shades — darker

Tints — lighter

Color harmonies

Nearest named colors

Ranked with CIEDE2000 across all 139 CSS keywords. Under ΔE 2 the eye stops telling them apart; over ΔE 10 they are plainly different colors.

#511ec3 in the real world

Where a color in this family tends to land, and the interface roles it is usually asked to play.

Industries
Creative toolsFintechBeautyLuxury
Common UI roles
ButtonsLinksFocus statesCharts
Print note

Converts to four-color process without much drama. Proof it anyway.

#511ec3, answered

What color is #511ec3?

#511ec3 is a dark vivid violet, closest to Medium Blue (ΔE2000 5.9). It sits at 259° on the hue wheel with 73% saturation and 44% lightness, which reads as cool.

What is the RGB value of #511ec3?

rgb(81, 30, 195) — 81 red, 30 green and 195 blue out of 255, or 31.8% / 11.8% / 76.5% by channel.

Is #511ec3 a light or a dark color?

It is a dark color. Relative luminance is 0.0662 and perceived brightness is 32%, so white text on it reaches 9.04:1.

Should I use black or white text on #511ec3?

White. It scores 9.04:1 against #511ec3, versus 2.32:1 for black — AAA at any size.

What is the complementary color of #511ec3?

#90C31E sits directly opposite on the wheel. Softer options are the split-complements #C3A31E and #3EC31E, which give the same contrast with far less vibration.

What colors go well with #511ec3?

For interface work: #F6F4FA as the surface, #CEC0ED for borders, #634B9B for secondary text, #ABB418 as an accent and #2E116E for hover and pressed states. For a palette, the analogous pair #1E3EC3 and #A31EC3 stays calm, while #90C31E is the loudest partner.

What is #511ec3 in CMYK for printing?

cmyk(59%, 85%, 0%, 24%). This is a screen-to-ink approximation — ask your printer for a proof before committing to a run.

Is #511ec3 warm or cool?

Cool — it scores 73 on a scale where 0 is the warmest orange and 100 the coolest azure. Nudged warmer it becomes #8D1EC3; nudged cooler, #1C26C5.

Work with #511ec3 in the Color Lab