Skip to content

#5a5821

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

RGB
90, 88, 33
HSL
58°, 46%, 24%
CMYK
0, 2, 63, 65
Luminance
0.0926

At a glance

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

Hex
#5a5821
Hue
58°
yellow
Saturation
46%
vivid
Lightness
24%
deep
Brightness
35%
HSV value
Perceived
33%
weighted brightness
Luminance
0.0926
WCAG relative
Temperature
Warm
23/100 cool
Color family
Yellow
Tone
Vivid
Best ink
White
7.36:1
Closest name
Dark Olive Green
ΔE2000 9.2
Where it sits
Hue58° of 360°
Saturation46%
Lightness24%
Temperature
Warm ← → Cool23% 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#5a5821
RGBrgb(90, 88, 33)
HSLhsl(58, 46%, 24%)
CMYKcmyk(0%, 2%, 63%, 65%)
LABlab(36.5 -7.3 31.4)
LCHlch(36.5 32.3 103.0)
OKLCHoklch(0.450 0.076 107.1)
Decimal5920801
Display P3color(display-p3 0.353 0.345 0.129)

Copy-ready code

/* CSS */
color: #5a5821;
background-color: #5a5821;
/* Tailwind (arbitrary) */
class="text-[#5a5821] bg-[#5a5821]"
/* SCSS */
$brand: #5a5821;
/* SwiftUI */
Color(red: 0.353, green: 0.345, blue: 0.129)
/* Android */
Color.parseColor("#5a5821")
/* Flutter */
Color(0xFF5A5821)
/* Python / OpenCV (BGR) */
(33, 88, 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 #5a5821 · 7.36:1
Use #ffffffAAA at every size.
Aa
White text · 7.36:1 · recommended
AA pass · AA large pass · AAA pass
Aa
Black text · 2.85:1
AA fail · AA large fail · AAA fail
Reading the other direction: #5a5821 as text scores 7.36:1 on white and 2.85:1 on black.

Accessibility — WCAG contrast

Aa
#5a5821 on white: 7.36:1
AA ✓ pass · AA-large · AAA
Aa
#5a5821 on black: 2.85:1
AA ✗ fail · AA-large · AAA
true color
protanopia · #5F551B
deuteranopia · #605724
tritanopia · #60524C

Color scale — 50 to 950

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

#FAFAF5
#F5F5EA
#EBEAD0
#E1DFAD
#D2CF84
#C3BF5B
#B3AF42
#959237
#77752C
#5a5821
#373516
Base = 900Lightest = 50 · #FAFAF5Darkest = 950 · #373516
:root {
  --brand-50: #FAFAF5;
  --brand-100: #F5F5EA;
  --brand-200: #EBEAD0;
  --brand-300: #E1DFAD;
  --brand-400: #D2CF84;
  --brand-500: #C3BF5B;
  --brand-600: #B3AF42;
  --brand-700: #959237;
  --brand-800: #77752C;
  --brand-900: #5a5821;
  --brand-950: #373516;
  --brand: #5a5821;
  --brand-ink: #ffffff;
}

Colors that work with #5a5821

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#E9E8C3
Hairlines and dividers
Muted text#9B984B
Captions on the surface
Accent#1F305C
Second voice, not a rival
Dark variant#5D5B22
Hover, pressed, headers
Light variant#F8F8EC
Selected rows, tints
Dark surface#242414
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 #5a5821

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
  • Text on black or near-black surfaces
  • 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#21235A
Analogous left#5A3B21
Analogous right#3F5A21
Split-complement 1#213F5A
Split-complement 2#3B215A
Triadic 1#215A58
Triadic 2#58215A
Tetradic#215A3B

RGB percentages

Red35.3%
Green34.5%
Blue12.9%

CMYK percentages

Cyan0.0%
Magenta2.2%
Yellow63.3%
Key (black)64.7%

Color previews

#5a5821 text on a black background

contrast 2.85:1

Card sample

#5a5821 text on a white background

contrast 7.36:1

Card sample

CSS3 live lab

Text font color

The quick brown fox

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

Glowing headline

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

Soft neon halo

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

Monochromatic scale

Palettes built from #5a5821

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.

#5a5821 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.

#5a5821, answered

What color is #5a5821?

#5a5821 is a deep vivid yellow, closest to Dark Olive Green (ΔE2000 9.2). It sits at 58° on the hue wheel with 46% saturation and 24% lightness, which reads as warm.

What is the RGB value of #5a5821?

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

Is #5a5821 a light or a dark color?

It is a dark color. Relative luminance is 0.0926 and perceived brightness is 33%, so white text on it reaches 7.36:1.

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

White. It scores 7.36:1 against #5a5821, versus 2.85:1 for black — AAA at any size.

What is the complementary color of #5a5821?

#21235A sits directly opposite on the wheel. Softer options are the split-complements #213F5A and #3B215A, which give the same contrast with far less vibration.

What colors go well with #5a5821?

For interface work: #FAFAF4 as the surface, #E9E8C3 for borders, #9B984B for secondary text, #1F305C as an accent and #5D5B22 for hover and pressed states. For a palette, the analogous pair #5A3B21 and #3F5A21 stays calm, while #21235A is the loudest partner.

What is #5a5821 in CMYK for printing?

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

Is #5a5821 warm or cool?

Warm — it scores 23 on a scale where 0 is the warmest orange and 100 the coolest azure. Nudged warmer it becomes #5A4321; nudged cooler, #475B20.

Work with #5a5821 in the Color Lab