Skip to content

#9b42ff

a balanced, electric violet · cool · closest name: Blue Violet

RGB
155, 66, 255
HSL
268°, 100%, 63%
CMYK
39, 74, 0, 0
Luminance
0.1808

At a glance

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

Hex
#9b42ff
Hue
268°
violet
Saturation
100%
electric
Lightness
63%
balanced
Brightness
100%
HSV value
Perceived
51%
weighted brightness
Luminance
0.1808
WCAG relative
Temperature
Cool
68/100 cool
Color family
Violet
Tone
Electric
Best ink
Black
4.62:1
Closest name
Blue Violet
ΔE2000 7.2
Where it sits
Hue268° of 360°
Saturation100%
Lightness63%
Temperature
Warm ← → Cool68% 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#9b42ff
RGBrgb(155, 66, 255)
HSLhsl(268, 100%, 63%)
CMYKcmyk(39%, 74%, 0%, 0%)
LABlab(49.6 70.5 -78.9)
LCHlch(49.6 105.8 311.8)
OKLCHoklch(0.597 0.260 299.8)
Decimal10175231
Display P3color(display-p3 0.608 0.259 1.000)

Copy-ready code

/* CSS */
color: #9b42ff;
background-color: #9b42ff;
/* Tailwind (arbitrary) */
class="text-[#9b42ff] bg-[#9b42ff]"
/* SCSS */
$brand: #9b42ff;
/* SwiftUI */
Color(red: 0.608, green: 0.259, blue: 1.000)
/* Android */
Color.parseColor("#9b42ff")
/* Flutter */
Color(0xFF9B42FF)
/* Python / OpenCV (BGR) */
(255, 66, 155)

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

Accessibility — WCAG contrast

Aa
#9b42ff on white: 4.55:1
AA ✓ pass · AA-large · AAA
Aa
#9b42ff on black: 4.62:1
AA ✓ pass · AA-large · AAA
true color
protanopia · #0076FF
deuteranopia · #0074FB
tritanopia · #83739E

Color scale — 50 to 950

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

#F7F1FE
#EFE3FC
#DCC0FC
#C48FFF
#9b42ff
#881FFF
#7300F5
#6000CC
#4D00A3
#3A0576
#240349
Base = 400Lightest = 50 · #F7F1FEDarkest = 950 · #240349
:root {
  --brand-50: #F7F1FE;
  --brand-100: #EFE3FC;
  --brand-200: #DCC0FC;
  --brand-300: #C48FFF;
  --brand-400: #9b42ff;
  --brand-500: #881FFF;
  --brand-600: #7300F5;
  --brand-700: #6000CC;
  --brand-800: #4D00A3;
  --brand-900: #3A0576;
  --brand-950: #240349;
  --brand: #9b42ff;
  --brand-ink: #000000;
}

Colors that work with #9b42ff

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#F7F4FA
Tinted page background
Border#D5C0ED
Hairlines and dividers
Muted text#704B9B
Captions on the surface
Accent#9FCC00
Second voice, not a rival
Dark variant#3C0080
Hover, pressed, headers
Light variant#F2E5FF
Selected rows, tints
Dark surface#1C1424
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 #9b42ff

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

Works well for
  • Body text and links 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
  • 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#A6FF42
Analogous left#4247FF
Analogous right#FA42FF
Split-complement 1#FFFA42
Split-complement 2#47FF42
Triadic 1#FF9B42
Triadic 2#42FF9B
Tetradic#FF4247

RGB percentages

Red60.8%
Green25.9%
Blue100.0%

CMYK percentages

Cyan39.2%
Magenta74.1%
Yellow0.0%
Key (black)0.0%

Color previews

#9b42ff text on a black background

contrast 4.62:1

Card sample

#9b42ff text on a white background

contrast 4.55:1

Card sample

CSS3 live lab

Text font color

The quick brown fox

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

Glowing headline

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

Soft neon halo

text-shadow: 0 0 14px rgba(155, 66, 255, 0.45);
Div box shadow
Elevated card
box-shadow: 0 12px 32px -8px rgba(155, 66, 255, 0.45);
Border & gradient
Gradient panel
border: 3px solid #9b42ff;
background: linear-gradient(135deg, #9b42ff, #FF42E5);

Monochromatic scale

Palettes built from #9b42ff

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.

#9b42ff 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.

#9b42ff, answered

What color is #9b42ff?

#9b42ff is a balanced electric violet, closest to Blue Violet (ΔE2000 7.2). It sits at 268° on the hue wheel with 100% saturation and 63% lightness, which reads as cool.

What is the RGB value of #9b42ff?

rgb(155, 66, 255) — 155 red, 66 green and 255 blue out of 255, or 60.8% / 25.9% / 100% by channel.

Is #9b42ff a light or a dark color?

It is a mid-tone. Relative luminance is 0.1808 and perceived brightness is 51%, so black text on it reaches 4.62:1.

Should I use black or white text on #9b42ff?

Black. It scores 4.62:1 against #9b42ff, versus 4.55:1 for white — AA at any size.

What is the complementary color of #9b42ff?

#A6FF42 sits directly opposite on the wheel. Softer options are the split-complements #FFFA42 and #47FF42, which give the same contrast with far less vibration.

What colors go well with #9b42ff?

For interface work: #F7F4FA as the surface, #D5C0ED for borders, #704B9B for secondary text, #9FCC00 as an accent and #3C0080 for hover and pressed states. For a palette, the analogous pair #4247FF and #FA42FF stays calm, while #A6FF42 is the loudest partner.

What is #9b42ff in CMYK for printing?

cmyk(39%, 74%, 0%, 0%). 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 #9b42ff warm or cool?

Cool — it scores 68 on a scale where 0 is the warmest orange and 100 the coolest azure. Nudged warmer it becomes #E042FF; nudged cooler, #5642FF.

Work with #9b42ff in the Color Lab