Skip to content

#cd40f8

a balanced, electric violet · neutral · closest name: Medium Orchid

RGB
205, 64, 248
HSL
286°, 93%, 61%
CMYK
17, 74, 0, 3
Luminance
0.2342

At a glance

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

Hex
#cd40f8
Hue
286°
violet
Saturation
93%
electric
Lightness
61%
balanced
Brightness
97%
HSV value
Perceived
58%
weighted brightness
Luminance
0.2342
WCAG relative
Temperature
Neutral
58/100 cool
Color family
Violet
Tone
Electric
Best ink
Black
5.68:1
Closest name
Medium Orchid
ΔE2000 5.6
Where it sits
Hue286° of 360°
Saturation93%
Lightness61%
Temperature
Warm ← → Cool58% cool

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

Every format

HEX#cd40f8
RGBrgb(205, 64, 248)
HSLhsl(286, 93%, 61%)
CMYKcmyk(17%, 74%, 0%, 3%)
LABlab(55.5 78.4 -65.1)
LCHlch(55.5 101.9 320.3)
OKLCHoklch(0.651 0.268 316.9)
Decimal13451512
Display P3color(display-p3 0.804 0.251 0.973)

Copy-ready code

/* CSS */
color: #cd40f8;
background-color: #cd40f8;
/* Tailwind (arbitrary) */
class="text-[#cd40f8] bg-[#cd40f8]"
/* SCSS */
$brand: #cd40f8;
/* SwiftUI */
Color(red: 0.804, green: 0.251, blue: 0.973)
/* Android */
Color.parseColor("#cd40f8")
/* Flutter */
Color(0xFFCD40F8)
/* Python / OpenCV (BGR) */
(248, 64, 205)

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

Accessibility — WCAG contrast

Aa
#cd40f8 on white: 3.69:1
AA ✗ fail · AA-large · AAA
Aa
#cd40f8 on black: 5.68:1
AA ✓ pass · AA-large · AAA
true color
protanopia · #007DFD
deuteranopia · #4289F4
tritanopia · #CB689A

Color scale — 50 to 950

A Tailwind-shaped ramp built around this exact hex. #cd40f8 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.

#FAF2FD
#F6E4FB
#EDC2F9
#E393FB
#D55DF9
#cd40f8
#B709EC
#9907C5
#7A069D
#590972
#380647
Base = 500Lightest = 50 · #FAF2FDDarkest = 950 · #380647
:root {
  --brand-50: #FAF2FD;
  --brand-100: #F6E4FB;
  --brand-200: #EDC2F9;
  --brand-300: #E393FB;
  --brand-400: #D55DF9;
  --brand-500: #cd40f8;
  --brand-600: #B709EC;
  --brand-700: #9907C5;
  --brand-800: #7A069D;
  --brand-900: #590972;
  --brand-950: #380647;
  --brand: #cd40f8;
  --brand-ink: #000000;
}

Colors that work with #cd40f8

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

Text on it#000000
Black wins here
Surface#F9F4FA
Tinted page background
Border#E2C0ED
Hairlines and dividers
Muted text#884B9B
Captions on the surface
Accent#63C903
Second voice, not a rival
Dark variant#5F057B
Hover, pressed, headers
Light variant#F9E6FE
Selected rows, tints
Dark surface#211424
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 #cd40f8

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

Works well for
  • Headings from 24px up on white
  • Text and icons on dark surfaces
  • Primary buttons and calls to action
  • Focus rings, active and selected states
  • Brand accents, badges and data highlights
Use with care
  • Small text on white — under 4.5:1
  • 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#6BF840
Analogous left#7140F8
Analogous right#F840C7
Split-complement 1#C7F840
Split-complement 2#40F871
Triadic 1#F8CD40
Triadic 2#40F8CD
Tetradic#F87140

RGB percentages

Red80.4%
Green25.1%
Blue97.3%

CMYK percentages

Cyan17.3%
Magenta74.2%
Yellow0.0%
Key (black)2.7%

Color previews

#cd40f8 text on a black background

contrast 5.68:1

Card sample

#cd40f8 text on a white background

contrast 3.69:1

Card sample

CSS3 live lab

Text font color

The quick brown fox

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

Glowing headline

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

Soft neon halo

text-shadow: 0 0 14px rgba(205, 64, 248, 0.45);
Div box shadow
Elevated card
box-shadow: 0 12px 32px -8px rgba(205, 64, 248, 0.45);
Border & gradient
Gradient panel
border: 3px solid #cd40f8;
background: linear-gradient(135deg, #cd40f8, #F840A8);

Monochromatic scale

Palettes built from #cd40f8

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.

#cd40f8 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

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

#cd40f8, answered

What color is #cd40f8?

#cd40f8 is a balanced electric violet, closest to Medium Orchid (ΔE2000 5.6). It sits at 286° on the hue wheel with 93% saturation and 61% lightness, which reads as neutral.

What is the RGB value of #cd40f8?

rgb(205, 64, 248) — 205 red, 64 green and 248 blue out of 255, or 80.4% / 25.1% / 97.3% by channel.

Is #cd40f8 a light or a dark color?

It is a mid-tone. Relative luminance is 0.2342 and perceived brightness is 58%, so black text on it reaches 5.68:1.

Should I use black or white text on #cd40f8?

Black. It scores 5.68:1 against #cd40f8, versus 3.69:1 for white — AA at any size.

What is the complementary color of #cd40f8?

#6BF840 sits directly opposite on the wheel. Softer options are the split-complements #C7F840 and #40F871, which give the same contrast with far less vibration.

What colors go well with #cd40f8?

For interface work: #F9F4FA as the surface, #E2C0ED for borders, #884B9B for secondary text, #63C903 as an accent and #5F057B for hover and pressed states. For a palette, the analogous pair #7140F8 and #F840C7 stays calm, while #6BF840 is the loudest partner.

What is #cd40f8 in CMYK for printing?

cmyk(17%, 74%, 0%, 3%). 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 #cd40f8 warm or cool?

Neutral — it scores 58 on a scale where 0 is the warmest orange and 100 the coolest azure. Nudged warmer it becomes #F840DF; nudged cooler, #893EFA.

Work with #cd40f8 in the Color Lab