Skip to content

#af31df

a balanced, vivid violet · cool · closest name: Dark Orchid

RGB
175, 49, 223
HSL
283°, 73%, 53%
CMYK
22, 78, 0, 13
Luminance
0.1664

At a glance

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

Hex
#af31df
Hue
283°
violet
Saturation
73%
vivid
Lightness
53%
balanced
Brightness
87%
HSV value
Perceived
50%
weighted brightness
Luminance
0.1664
WCAG relative
Temperature
Cool
59/100 cool
Color family
Violet
Tone
Vivid
Best ink
White
4.85:1
Closest name
Dark Orchid
ΔE2000 4.6
Where it sits
Hue283° of 360°
Saturation73%
Lightness53%
Temperature
Warm ← → Cool59% 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#af31df
RGBrgb(175, 49, 223)
HSLhsl(283, 73%, 53%)
CMYKcmyk(22%, 78%, 0%, 13%)
LABlab(47.8 73.2 -63.7)
LCHlch(47.8 97.0 319.0)
OKLCHoklch(0.583 0.252 314.3)
Decimal11481567
Display P3color(display-p3 0.686 0.192 0.875)

Copy-ready code

/* CSS */
color: #af31df;
background-color: #af31df;
/* Tailwind (arbitrary) */
class="text-[#af31df] bg-[#af31df]"
/* SCSS */
$brand: #af31df;
/* SwiftUI */
Color(red: 0.686, green: 0.192, blue: 0.875)
/* Android */
Color.parseColor("#af31df")
/* Flutter */
Color(0xFFAF31DF)
/* Python / OpenCV (BGR) */
(223, 49, 175)

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 #af31df · 4.85:1
Use #ffffffAA at every size, AAA for large text only.
Aa
White text · 4.85:1 · recommended
AA pass · AA large pass · AAA fail
Aa
Black text · 4.33:1
AA fail · AA large pass · AAA fail
Reading the other direction: #af31df as text scores 4.85:1 on white and 4.33:1 on black.

Accessibility — WCAG contrast

Aa
#af31df on white: 4.85:1
AA ✓ pass · AA-large · AAA
Aa
#af31df on black: 4.33:1
AA ✗ fail · AA-large · AAA
true color
protanopia · #006BE4
deuteranopia · #2274DB
tritanopia · #AA5B88

Color scale — 50 to 950

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

#F9F3FC
#F4E7F8
#E7C9F3
#D99EF0
#C66DE8
#af31df
#A221D4
#871BB1
#6C168D
#501466
#320D40
Base = 500Lightest = 50 · #F9F3FCDarkest = 950 · #320D40
:root {
  --brand-50: #F9F3FC;
  --brand-100: #F4E7F8;
  --brand-200: #E7C9F3;
  --brand-300: #D99EF0;
  --brand-400: #C66DE8;
  --brand-500: #af31df;
  --brand-600: #A221D4;
  --brand-700: #871BB1;
  --brand-800: #6C168D;
  --brand-900: #501466;
  --brand-950: #320D40;
  --brand: #af31df;
  --brand-ink: #ffffff;
}

Colors that work with #af31df

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#F9F4FA
Tinted page background
Border#E0C0ED
Hairlines and dividers
Muted text#854B9B
Captions on the surface
Accent#6AB517
Second voice, not a rival
Dark variant#55116E
Hover, pressed, headers
Light variant#F6E9FC
Selected rows, tints
Dark surface#201424
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 #af31df

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
  • Brand accents, badges and data highlights
Use with care
  • Full-page backgrounds — tiring over long sessions
  • 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#61DF31
Analogous left#5831DF
Analogous right#DF31B8
Split-complement 1#B8DF31
Split-complement 2#31DF58
Triadic 1#DFAF31
Triadic 2#31DFAF
Tetradic#DF5831

RGB percentages

Red68.6%
Green19.2%
Blue87.5%

CMYK percentages

Cyan21.5%
Magenta78.0%
Yellow0.0%
Key (black)12.5%

Color previews

#af31df text on a black background

contrast 4.33:1

Card sample

#af31df text on a white background

contrast 4.85:1

Card sample

CSS3 live lab

Text font color

The quick brown fox

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

Glowing headline

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

Soft neon halo

text-shadow: 0 0 14px rgba(175, 49, 223, 0.45);
Div box shadow
Elevated card
box-shadow: 0 12px 32px -8px rgba(175, 49, 223, 0.45);
Border & gradient
Gradient panel
border: 3px solid #af31df;
background: linear-gradient(135deg, #af31df, #DF319B);

Monochromatic scale

Palettes built from #af31df

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.

#af31df 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.

#af31df, answered

What color is #af31df?

#af31df is a balanced vivid violet, closest to Dark Orchid (ΔE2000 4.6). It sits at 283° on the hue wheel with 73% saturation and 53% lightness, which reads as cool.

What is the RGB value of #af31df?

rgb(175, 49, 223) — 175 red, 49 green and 223 blue out of 255, or 68.6% / 19.2% / 87.5% by channel.

Is #af31df a light or a dark color?

It is a dark color. Relative luminance is 0.1664 and perceived brightness is 50%, so white text on it reaches 4.85:1.

Should I use black or white text on #af31df?

White. It scores 4.85:1 against #af31df, versus 4.33:1 for black — AA at any size.

What is the complementary color of #af31df?

#61DF31 sits directly opposite on the wheel. Softer options are the split-complements #B8DF31 and #31DF58, which give the same contrast with far less vibration.

What colors go well with #af31df?

For interface work: #F9F4FA as the surface, #E0C0ED for borders, #854B9B for secondary text, #6AB517 as an accent and #55116E for hover and pressed states. For a palette, the analogous pair #5831DF and #DF31B8 stays calm, while #61DF31 is the loudest partner.

What is #af31df in CMYK for printing?

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

Is #af31df warm or cool?

Cool — it scores 59 on a scale where 0 is the warmest orange and 100 the coolest azure. Nudged warmer it becomes #DF31CF; nudged cooler, #6E2EE1.

Work with #af31df in the Color Lab