Skip to content

#5f5baf

a balanced, soft blue · cool · closest name: Slate Blue

RGB
95, 91, 175
HSL
243°, 34%, 52%
CMYK
46, 48, 0, 31
Luminance
0.1301

At a glance

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

Hex
#5f5baf
Hue
243°
blue
Saturation
34%
soft
Lightness
52%
balanced
Brightness
69%
HSV value
Perceived
41%
weighted brightness
Luminance
0.1301
WCAG relative
Temperature
Cool
81/100 cool
Color family
Blue
Tone
Soft
Best ink
White
5.83:1
Closest name
Slate Blue
ΔE2000 5.1
Where it sits
Hue243° of 360°
Saturation34%
Lightness52%
Temperature
Warm ← → Cool81% 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#5f5baf
RGBrgb(95, 91, 175)
HSLhsl(243, 34%, 52%)
CMYKcmyk(46%, 48%, 0%, 31%)
LABlab(42.8 23.9 -44.5)
LCHlch(42.8 50.5 298.2)
OKLCHoklch(0.516 0.130 283.0)
Decimal6249391
Display P3color(display-p3 0.373 0.357 0.686)

Copy-ready code

/* CSS */
color: #5f5baf;
background-color: #5f5baf;
/* Tailwind (arbitrary) */
class="text-[#5f5baf] bg-[#5f5baf]"
/* SCSS */
$brand: #5f5baf;
/* SwiftUI */
Color(red: 0.373, green: 0.357, blue: 0.686)
/* Android */
Color.parseColor("#5f5baf")
/* Flutter */
Color(0xFF5F5BAF)
/* Python / OpenCV (BGR) */
(175, 91, 95)

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

Accessibility — WCAG contrast

Aa
#5f5baf on white: 5.83:1
AA ✓ pass · AA-large · AAA
Aa
#5f5baf on black: 3.60:1
AA ✗ fail · AA-large · AAA
true color
protanopia · #3868B2
deuteranopia · #3462AD
tritanopia · #456D7C

Color scale — 50 to 950

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

#F5F5F9
#ECECF4
#D5D4E8
#B5B4DA
#918EC8
#5f5baf
#5450A5
#464389
#38366E
#2C2A51
#1B1A32
Base = 500Lightest = 50 · #F5F5F9Darkest = 950 · #1B1A32
:root {
  --brand-50: #F5F5F9;
  --brand-100: #ECECF4;
  --brand-200: #D5D4E8;
  --brand-300: #B5B4DA;
  --brand-400: #918EC8;
  --brand-500: #5f5baf;
  --brand-600: #5450A5;
  --brand-700: #464389;
  --brand-800: #38366E;
  --brand-900: #2C2A51;
  --brand-950: #1B1A32;
  --brand: #5f5baf;
  --brand-ink: #ffffff;
}

Colors that work with #5f5baf

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#F5F5FA
Tinted page background
Border#CAC8E4
Hairlines and dividers
Muted text#4F4B9A
Captions on the surface
Accent#8D7D3F
Second voice, not a rival
Dark variant#2C2A56
Hover, pressed, headers
Light variant#EEEEF7
Selected rows, tints
Dark surface#141424
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 #5f5baf

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

Works well for
  • Body text and links on white
  • Charts, tags and secondary surfaces
  • Brand accents, badges and data highlights
Use with care
  • 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#ABAF5B
Analogous left#5B81AF
Analogous right#895BAF
Split-complement 1#AF895B
Split-complement 2#81AF5B
Triadic 1#AF5F5B
Triadic 2#5BAF5F
Tetradic#AF5B81

RGB percentages

Red37.3%
Green35.7%
Blue68.6%

CMYK percentages

Cyan45.7%
Magenta48.0%
Yellow0.0%
Key (black)31.4%

Color previews

#5f5baf text on a black background

contrast 3.60:1

Card sample

#5f5baf text on a white background

contrast 5.83:1

Card sample

CSS3 live lab

Text font color

The quick brown fox

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

Glowing headline

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

Soft neon halo

text-shadow: 0 0 14px rgba(95, 91, 175, 0.45);
Div box shadow
Elevated card
box-shadow: 0 12px 32px -8px rgba(95, 91, 175, 0.45);
Border & gradient
Gradient panel
border: 3px solid #5f5baf;
background: linear-gradient(135deg, #5f5baf, #975BAF);

Monochromatic scale

Palettes built from #5f5baf

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.

#5f5baf in the real world

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

Industries
TechnologyFinanceHealthcareEnterprise SaaS
Common UI roles
ButtonsLinksFocus statesCharts
Print note

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

#5f5baf, answered

What color is #5f5baf?

#5f5baf is a balanced soft blue, closest to Slate Blue (ΔE2000 5.1). It sits at 243° on the hue wheel with 34% saturation and 52% lightness, which reads as cool.

What is the RGB value of #5f5baf?

rgb(95, 91, 175) — 95 red, 91 green and 175 blue out of 255, or 37.3% / 35.7% / 68.6% by channel.

Is #5f5baf a light or a dark color?

It is a dark color. Relative luminance is 0.1301 and perceived brightness is 41%, so white text on it reaches 5.83:1.

Should I use black or white text on #5f5baf?

White. It scores 5.83:1 against #5f5baf, versus 3.60:1 for black — AA at any size.

What is the complementary color of #5f5baf?

#ABAF5B sits directly opposite on the wheel. Softer options are the split-complements #AF895B and #81AF5B, which give the same contrast with far less vibration.

What colors go well with #5f5baf?

For interface work: #F5F5FA as the surface, #CAC8E4 for borders, #4F4B9A for secondary text, #8D7D3F as an accent and #2C2A56 for hover and pressed states. For a palette, the analogous pair #5B81AF and #895BAF stays calm, while #ABAF5B is the loudest partner.

What is #5f5baf in CMYK for printing?

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

Is #5f5baf warm or cool?

Cool — it scores 81 on a scale where 0 is the warmest orange and 100 the coolest azure. Nudged warmer it becomes #7E5BAF; nudged cooler, #5975B1.

Work with #5f5baf in the Color Lab