Skip to content

#1f0afd

a balanced, electric blue · cool · “Blue”

RGB
31, 10, 253
HSL
245°, 98%, 52%
CMYK
88, 96, 0, 1
Luminance
0.0760

At a glance

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

Hex
#1f0afd
Hue
245°
blue
Saturation
98%
electric
Lightness
52%
balanced
Brightness
99%
HSV value
Perceived
34%
weighted brightness
Luminance
0.0760
WCAG relative
Temperature
Cool
80/100 cool
Color family
Blue
Tone
Electric
Best ink
White
8.33:1
Closest name
Blue
ΔE2000 0.8
Where it sits
Hue245° of 360°
Saturation98%
Lightness52%
Temperature
Warm ← → Cool80% 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#1f0afd
RGBrgb(31, 10, 253)
HSLhsl(245, 98%, 52%)
CMYKcmyk(88%, 96%, 0%, 1%)
LABlab(33.1 77.5 -105.3)
LCHlch(33.1 130.8 306.3)
OKLCHoklch(0.459 0.305 267.0)
Decimal2034429
Display P3color(display-p3 0.122 0.039 0.992)

Copy-ready code

/* CSS */
color: #1f0afd;
background-color: #1f0afd;
/* Tailwind (arbitrary) */
class="text-[#1f0afd] bg-[#1f0afd]"
/* SCSS */
$brand: #1f0afd;
/* SwiftUI */
Color(red: 0.122, green: 0.039, blue: 0.992)
/* Android */
Color.parseColor("#1f0afd")
/* Flutter */
Color(0xFF1F0AFD)
/* Python / OpenCV (BGR) */
(253, 10, 31)

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 #1f0afd · 8.33:1
Use #ffffffAAA at every size.
Aa
White text · 8.33:1 · recommended
AA pass · AA large pass · AAA pass
Aa
Black text · 2.52:1
AA fail · AA large fail · AAA fail
Reading the other direction: #1f0afd as text scores 8.33:1 on white and 2.52:1 on black.

Accessibility — WCAG contrast

Aa
#1f0afd on white: 8.33:1
AA ✓ pass · AA-large · AAA
Aa
#1f0afd on black: 2.52:1
AA ✗ fail · AA-large · AAA
true color
protanopia · #005AFF
deuteranopia · #0041FA
tritanopia · #006B95

Color scale — 50 to 950

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

#F2F1FE
#E6E3FC
#C6C1FB
#9990FE
#6658FE
#3420FD
#1f0afd
#1302CA
#0F01A2
#0F0675
#0A0449
Base = 600Lightest = 50 · #F2F1FEDarkest = 950 · #0A0449
:root {
  --brand-50: #F2F1FE;
  --brand-100: #E6E3FC;
  --brand-200: #C6C1FB;
  --brand-300: #9990FE;
  --brand-400: #6658FE;
  --brand-500: #3420FD;
  --brand-600: #1f0afd;
  --brand-700: #1302CA;
  --brand-800: #0F01A2;
  --brand-900: #0F0675;
  --brand-950: #0A0449;
  --brand: #1f0afd;
  --brand-ink: #ffffff;
}

Colors that work with #1f0afd

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#F5F4FA
Tinted page background
Border#C4C0ED
Hairlines and dividers
Muted text#524B9B
Captions on the surface
Accent#CCAB00
Second voice, not a rival
Dark variant#0C017E
Hover, pressed, headers
Light variant#E8E6FF
Selected rows, tints
Dark surface#151424
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 #1f0afd

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
  • Text on black or near-black surfaces
  • 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#E8FD0A
Analogous left#0A6FFD
Analogous right#990AFD
Split-complement 1#FD990A
Split-complement 2#6FFD0A
Triadic 1#FD1F0A
Triadic 2#0AFD1F
Tetradic#FD0A6F

RGB percentages

Red12.2%
Green3.9%
Blue99.2%

CMYK percentages

Cyan87.7%
Magenta96.0%
Yellow0.0%
Key (black)0.8%

Color previews

#1f0afd text on a black background

contrast 2.52:1

Card sample

#1f0afd text on a white background

contrast 8.33:1

Card sample

CSS3 live lab

Text font color

The quick brown fox

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

Glowing headline

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

Soft neon halo

text-shadow: 0 0 14px rgba(31, 10, 253, 0.45);
Div box shadow
Elevated card
box-shadow: 0 12px 32px -8px rgba(31, 10, 253, 0.45);
Border & gradient
Gradient panel
border: 3px solid #1f0afd;
background: linear-gradient(135deg, #1f0afd, #C10AFD);

Monochromatic scale

Palettes built from #1f0afd

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.

#1f0afd 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

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

#1f0afd, answered

What color is #1f0afd?

#1f0afd is a balanced electric blue — the CSS keyword Blue. It sits at 245° on the hue wheel with 98% saturation and 52% lightness, which reads as cool.

What is the RGB value of #1f0afd?

rgb(31, 10, 253) — 31 red, 10 green and 253 blue out of 255, or 12.2% / 3.9% / 99.2% by channel.

Is #1f0afd a light or a dark color?

It is a dark color. Relative luminance is 0.0760 and perceived brightness is 34%, so white text on it reaches 8.33:1.

Should I use black or white text on #1f0afd?

White. It scores 8.33:1 against #1f0afd, versus 2.52:1 for black — AAA at any size.

What is the complementary color of #1f0afd?

#E8FD0A sits directly opposite on the wheel. Softer options are the split-complements #FD990A and #6FFD0A, which give the same contrast with far less vibration.

What colors go well with #1f0afd?

For interface work: #F5F4FA as the surface, #C4C0ED for borders, #524B9B for secondary text, #CCAB00 as an accent and #0C017E for hover and pressed states. For a palette, the analogous pair #0A6FFD and #990AFD stays calm, while #E8FD0A is the loudest partner.

What is #1f0afd in CMYK for printing?

cmyk(88%, 96%, 0%, 1%). 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 #1f0afd warm or cool?

Cool — it scores 80 on a scale where 0 is the warmest orange and 100 the coolest azure. Nudged warmer it becomes #780AFD; nudged cooler, #0832FF.

Work with #1f0afd in the Color Lab