Nearest named color: Royal Blue
#5171D1
#5171D1
Nearest named
Royal Blue
Family
Blue
Lightness
57.3%
Chroma
0.152
Hue angle
267.6°
Temperature
Cool
Contrast on white
4.53:1 · AA
Contrast on black
4.10:1 · AA Large
Web-safe
#6666CC
CSS oklch()
57% 0.15 268

#5171D1 is a mid-toned, cool violet. On the Color Lab it reads clean and engineered. It carries a legible label as a UI accent and sits well as a supporting tone.

Palettes built on #5171D1

Not just a swatch — here's how #5171D1 works with other colors. Named schemes with #5171D1 in its natural role, and a note on why the supporting colors balance it.

Coastal Morning Lead · 5 colors

Royal Blue opens this coastal palette with sea-glass and warm sand alongside it, grounded by driftwood grey and a deep-navy anchor.

Tech Product Signal · 5 colors

Royal Blue is the vivid signal in this product UI — on a near-black surface with cool white, a slate grey and a lighter tint of Royal Blue.

Vintage Leather Lead · 5 colors

Royal Blue plays the worn-leather lead, deepened by saddle brown and an oxblood anchor, softened by aged cream and cooled by a muted forest green.

Berry & Cream Lead · 5 colors

Royal Blue sits between cream and a deep berry here, softened by a blush accent and grounded by charcoal.

Minimal Editorial Surface · 5 colors

Royal Blue is the single accent in this high-contrast editorial system — set on near-white paper against near-black ink, with a warm grey and a desaturated tint of Royal Blue carrying the quiet middle.

Build a working theme in the generator →

Color Lab

How #5171D1 actually behaves in design work — read from its OKLCH lightness, chroma and hue, not just its raw numbers. Ten signals to help you decide where this color earns its place.

Warmth 14/100
Cool
Reads cool and recessive — calming, technical, good for trust-led UI.
Softness 42/100
Moderate
Middle-weight — neither delicate nor heavy.
Depth 44/100
Moderate
Mid depth — usable as an accent or a muted ground.
Naturalness 0/100
Very low
Reads engineered rather than organic — synthetic, digital.
Vintage feel 41/100
Moderate
A faint retro warmth without tipping into sepia.
Luxury 48/100
Moderate
Understated — leans refined without going austere.
Brand distinctiveness 41/100
Moderate
Recognisable but shares space with nearby hues.
UI accent fit 96/100
Very high
Strong interactive accent — visible and can carry a legible label.
Surface fit 14/100
Very low
Too saturated or mid-toned for big areas — keep it to accents.
Print safety 73/100
High
Reproduces faithfully in CMYK — safe for packaging and print.

Pairs with #5171D1

For UI
For branding
For interior
For fashion
People also use #5171D1 with

UI roles & guardrails

Primary action Safe as a filled button with white label. AA
Body text Passes on white at 16px and above. Pass
Large display Fine for headings 24px+ on white. Pass
Background Pair with white text at 4.5:1. Use
Subtle surface Use #E0E4F2 for cards and hover fills. Tint 80
Avoid beside #5C52D1 — the hue gap is too small to read as intentional. Clash

In real applications

Not a swatch to memorise — a color to build with. Here is #5171D1 at work across the surfaces designers actually ship.

Website / UI
Northwind Sign up
Build faster.
A working theme, generated in seconds.
Dashboard
Revenue
$48.2k ▲ 12%
Brand
AVELINE
Studio
Poster
Nov 14 · 8PM
NIGHT
MARKET
Packaging
BLOOM
Botanical Wash
250 ml
Interior

Scales

ShadesBase darkened in 10% steps
TintsBase lifted toward white
TonesSaturation removed, lightness held
Monochromatic scaleDesign-system ready, 50–900

Every model

Export

:root {
  --color-base: #5171D1;
  --color-base-rgb: 81 113 209;
  --color-base-oklch: oklch(57.3% 0.152 267.6);
  --color-50: #F2F5FC;
  --color-100: #DEE4F7;
  --color-200: #BFCAEE;
  --color-300: #92A5DD;
  --color-400: #6981C9;
  --color-500: #4761AD;
  --color-600: #3D4F85;
  --color-700: #303C5F;
  --color-800: #23293E;
  --color-900: #171B26;
  --color-on-base: #141310;
}