Skip to content

#af167f

a dark, electric magenta / pink · warm · closest name: Medium Violet Red

RGB
175, 22, 127
HSL
319°, 78%, 39%
CMYK
0, 87, 27, 31
Luminance
0.1122

At a glance

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

Hex
#af167f
Hue
319°
magenta / pink
Saturation
78%
electric
Lightness
39%
dark
Brightness
69%
HSV value
Perceived
42%
weighted brightness
Luminance
0.1122
WCAG relative
Temperature
Warm
40/100 cool
Color family
Magenta / pink
Tone
Electric
Best ink
White
6.47:1
Closest name
Medium Violet Red
ΔE2000 5
Where it sits
Hue319° of 360°
Saturation78%
Lightness39%
Temperature
Warm ← → Cool40% cool

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

Every format

HEX#af167f
RGBrgb(175, 22, 127)
HSLhsl(319, 78%, 39%)
CMYKcmyk(0%, 87%, 27%, 31%)
LABlab(40.0 64.9 -19.3)
LCHlch(40.0 67.7 343.5)
OKLCHoklch(0.510 0.204 345.5)
Decimal11474559
Display P3color(display-p3 0.686 0.086 0.498)

Copy-ready code

/* CSS */
color: #af167f;
background-color: #af167f;
/* Tailwind (arbitrary) */
class="text-[#af167f] bg-[#af167f]"
/* SCSS */
$brand: #af167f;
/* SwiftUI */
Color(red: 0.686, green: 0.086, blue: 0.498)
/* Android */
Color.parseColor("#af167f")
/* Flutter */
Color(0xFFAF167F)
/* Python / OpenCV (BGR) */
(127, 22, 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 #af167f · 6.47:1
Use #ffffffAA at every size, AAA for large text only.
Aa
White text · 6.47:1 · recommended
AA pass · AA large pass · AAA fail
Aa
Black text · 3.24:1
AA fail · AA large pass · AAA fail
Reading the other direction: #af167f as text scores 6.47:1 on white and 3.24:1 on black.

Accessibility — WCAG contrast

Aa
#af167f on white: 6.47:1
AA ✓ pass · AA-large · AAA
Aa
#af167f on black: 3.24:1
AA ✗ fail · AA-large · AAA
true color
protanopia · #314E81
deuteranopia · #60677C
tritanopia · #BB104C

Color scale — 50 to 950

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

#FCF3F9
#F9E6F3
#F5C7E6
#F29BD7
#EC69C3
#E638AF
#DA1B9E
#af167f
#911269
#69114E
#420B30
Base = 700Lightest = 50 · #FCF3F9Darkest = 950 · #420B30
:root {
  --brand-50: #FCF3F9;
  --brand-100: #F9E6F3;
  --brand-200: #F5C7E6;
  --brand-300: #F29BD7;
  --brand-400: #EC69C3;
  --brand-500: #E638AF;
  --brand-600: #DA1B9E;
  --brand-700: #af167f;
  --brand-800: #911269;
  --brand-900: #69114E;
  --brand-950: #420B30;
  --brand: #af167f;
  --brand-ink: #ffffff;
}

Colors that work with #af167f

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#FAF4F8
Tinted page background
Border#EDC0DF
Hairlines and dividers
Muted text#9B4B82
Captions on the surface
Accent#13B91D
Second voice, not a rival
Dark variant#710E52
Hover, pressed, headers
Light variant#FCE8F6
Selected rows, tints
Dark surface#24141F
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 #af167f

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
  • 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#16AF46
Analogous left#9216AF
Analogous right#AF1633
Split-complement 1#33AF16
Split-complement 2#16AF92
Triadic 1#7FAF16
Triadic 2#167FAF
Tetradic#AF9216

RGB percentages

Red68.6%
Green8.6%
Blue49.8%

CMYK percentages

Cyan0.0%
Magenta87.4%
Yellow27.4%
Key (black)31.4%

Color previews

#af167f text on a black background

contrast 3.24:1

Card sample

#af167f text on a white background

contrast 6.47:1

Card sample

CSS3 live lab

Text font color

The quick brown fox

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

Glowing headline

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

Soft neon halo

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

Monochromatic scale

Palettes built from #af167f

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.

#af167f in the real world

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

Industries
BeautyFashionLifestyleYouth brands
Common UI roles
ButtonsLinksFocus statesCharts
Print note

Sits outside most CMYK gamuts — expect a duller press result, or specify a spot ink.

#af167f, answered

What color is #af167f?

#af167f is a dark electric magenta / pink, closest to Medium Violet Red (ΔE2000 5). It sits at 319° on the hue wheel with 78% saturation and 39% lightness, which reads as warm.

What is the RGB value of #af167f?

rgb(175, 22, 127) — 175 red, 22 green and 127 blue out of 255, or 68.6% / 8.6% / 49.8% by channel.

Is #af167f a light or a dark color?

It is a dark color. Relative luminance is 0.1122 and perceived brightness is 42%, so white text on it reaches 6.47:1.

Should I use black or white text on #af167f?

White. It scores 6.47:1 against #af167f, versus 3.24:1 for black — AA at any size.

What is the complementary color of #af167f?

#16AF46 sits directly opposite on the wheel. Softer options are the split-complements #33AF16 and #16AF92, which give the same contrast with far less vibration.

What colors go well with #af167f?

For interface work: #FAF4F8 as the surface, #EDC0DF for borders, #9B4B82 for secondary text, #13B91D as an accent and #710E52 for hover and pressed states. For a palette, the analogous pair #9216AF and #AF1633 stays calm, while #16AF46 is the loudest partner.

What is #af167f in CMYK for printing?

cmyk(0%, 87%, 27%, 31%). This is a screen-to-ink approximation — a color this saturated sits outside most CMYK gamuts and will print duller than it looks here.

Is #af167f warm or cool?

Warm — it scores 40 on a scale where 0 is the warmest orange and 100 the coolest azure. Nudged warmer it becomes #AF1647; nudged cooler, #A914B1.

Work with #af167f in the Color Lab