Skip to content

#5a5e21

a deep, vivid yellow · warm · closest name: Dark Olive Green

RGB
90, 94, 33
HSL
64°, 48%, 25%
CMYK
4, 0, 65, 63
Luminance
0.1029

At a glance

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

Hex
#5a5e21
Hue
64°
yellow
Saturation
48%
vivid
Lightness
25%
deep
Brightness
37%
HSV value
Perceived
34%
weighted brightness
Luminance
0.1029
WCAG relative
Temperature
Warm
28/100 cool
Color family
Yellow
Tone
Vivid
Best ink
White
6.87:1
Closest name
Dark Olive Green
ΔE2000 6.6
Where it sits
Hue64° of 360°
Saturation48%
Lightness25%
Temperature
Warm ← → Cool28% cool

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

Every format

HEX#5a5e21
RGBrgb(90, 94, 33)
HSLhsl(64, 48%, 25%)
CMYKcmyk(4%, 0%, 65%, 63%)
LABlab(38.4 -10.8 33.5)
LCHlch(38.4 35.1 107.8)
OKLCHoklch(0.465 0.083 112.7)
Decimal5922337
Display P3color(display-p3 0.353 0.369 0.129)

Copy-ready code

/* CSS */
color: #5a5e21;
background-color: #5a5e21;
/* Tailwind (arbitrary) */
class="text-[#5a5e21] bg-[#5a5e21]"
/* SCSS */
$brand: #5a5e21;
/* SwiftUI */
Color(red: 0.353, green: 0.369, blue: 0.129)
/* Android */
Color.parseColor("#5a5e21")
/* Flutter */
Color(0xFF5A5E21)
/* Python / OpenCV (BGR) */
(33, 94, 90)

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

Accessibility — WCAG contrast

Aa
#5a5e21 on white: 6.87:1
AA ✓ pass · AA-large · AAA
Aa
#5a5e21 on black: 3.06:1
AA ✗ fail · AA-large · AAA
true color
protanopia · #655A1A
deuteranopia · #655B25
tritanopia · #605851

Color scale — 50 to 950

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

#FAFAF4
#F5F5EA
#EAECD0
#DEE2AC
#CED382
#BEC559
#AEB540
#919735
#74792A
#5a5e21
#353715
Base = 900Lightest = 50 · #FAFAF4Darkest = 950 · #353715
:root {
  --brand-50: #FAFAF4;
  --brand-100: #F5F5EA;
  --brand-200: #EAECD0;
  --brand-300: #DEE2AC;
  --brand-400: #CED382;
  --brand-500: #BEC559;
  --brand-600: #AEB540;
  --brand-700: #919735;
  --brand-800: #74792A;
  --brand-900: #5a5e21;
  --brand-950: #353715;
  --brand: #5a5e21;
  --brand-ink: #ffffff;
}

Colors that work with #5a5e21

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#FAFAF4
Tinted page background
Border#E7EAC3
Hairlines and dividers
Muted text#969B4B
Captions on the surface
Accent#1E2B61
Second voice, not a rival
Dark variant#5A5E21
Hover, pressed, headers
Light variant#F8F8EC
Selected rows, tints
Dark surface#232414
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 #5a5e21

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
  • Headers, footers and dark-mode surfaces
  • Brand accents, badges and data highlights
Use with care
  • Full-page backgrounds — tiring over long sessions
  • Black text placed on it
  • Thin strokes and 1px borders — they disappear on light UI
  • 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#25215E
Analogous left#5E4321
Analogous right#3C5E21
Split-complement 1#213C5E
Split-complement 2#43215E
Triadic 1#215A5E
Triadic 2#5E215A
Tetradic#215E43

RGB percentages

Red35.3%
Green36.9%
Blue12.9%

CMYK percentages

Cyan4.3%
Magenta0.0%
Yellow64.9%
Key (black)63.1%

Color previews

#5a5e21 text on a black background

contrast 3.06:1

Card sample

#5a5e21 text on a white background

contrast 6.87:1

Card sample

CSS3 live lab

Text font color

The quick brown fox

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

Glowing headline

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

Soft neon halo

text-shadow: 0 0 14px rgba(90, 94, 33, 0.45);
Div box shadow
Elevated card
box-shadow: 0 12px 32px -8px rgba(90, 94, 33, 0.45);
Border & gradient
Gradient panel
border: 3px solid #5a5e21;
background: linear-gradient(135deg, #5a5e21, #315E21);

Monochromatic scale

Palettes built from #5a5e21

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.

#5a5e21 in the real world

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

Industries
RetailLeisureEnergyWarning systems
Common UI roles
ButtonsLinksFocus statesCharts
Print note

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

#5a5e21, answered

What color is #5a5e21?

#5a5e21 is a deep vivid yellow, closest to Dark Olive Green (ΔE2000 6.6). It sits at 64° on the hue wheel with 48% saturation and 25% lightness, which reads as warm.

What is the RGB value of #5a5e21?

rgb(90, 94, 33) — 90 red, 94 green and 33 blue out of 255, or 35.3% / 36.9% / 12.9% by channel.

Is #5a5e21 a light or a dark color?

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

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

White. It scores 6.87:1 against #5a5e21, versus 3.06:1 for black — AA at any size.

What is the complementary color of #5a5e21?

#25215E sits directly opposite on the wheel. Softer options are the split-complements #213C5E and #43215E, which give the same contrast with far less vibration.

What colors go well with #5a5e21?

For interface work: #FAFAF4 as the surface, #E7EAC3 for borders, #969B4B for secondary text, #1E2B61 as an accent and #5A5E21 for hover and pressed states. For a palette, the analogous pair #5E4321 and #3C5E21 stays calm, while #25215E is the loudest partner.

What is #5a5e21 in CMYK for printing?

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

Is #5a5e21 warm or cool?

Warm — it scores 28 on a scale where 0 is the warmest orange and 100 the coolest azure. Nudged warmer it becomes #5E4C21; nudged cooler, #445F20.

Work with #5a5e21 in the Color Lab