Skip to content

#a7af5f

a balanced, soft yellow · warm · closest name: Dark Khaki

RGB
167, 175, 95
HSL
66°, 33%, 53%
CMYK
5, 0, 46, 31
Luminance
0.3970

At a glance

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

Hex
#a7af5f
Hue
66°
yellow
Saturation
33%
soft
Lightness
53%
balanced
Brightness
69%
HSV value
Perceived
65%
weighted brightness
Luminance
0.3970
WCAG relative
Temperature
Warm
31/100 cool
Color family
Yellow
Tone
Soft
Best ink
Black
8.94:1
Closest name
Dark Khaki
ΔE2000 5
Where it sits
Hue66° of 360°
Saturation33%
Lightness53%
Temperature
Warm ← → Cool31% 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#a7af5f
RGBrgb(167, 175, 95)
HSLhsl(66, 33%, 53%)
CMYKcmyk(5%, 0%, 46%, 31%)
LABlab(69.3 -14.9 39.9)
LCHlch(69.3 42.6 110.5)
OKLCHoklch(0.730 0.104 113.7)
Decimal10989407
Display P3color(display-p3 0.655 0.686 0.373)

Copy-ready code

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

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

Accessibility — WCAG contrast

Aa
#a7af5f on white: 2.35:1
AA ✗ fail · AA-large · AAA
Aa
#a7af5f on black: 8.94:1
AA ✓ pass · AA-large · AAA
true color
protanopia · #B9A858
deuteranopia · #B9AA63
tritanopia · #B0A79C

Color scale — 50 to 950

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

#F9F9F5
#F3F4EC
#E6E8D4
#D6DAB4
#C1C78F
#a7af5f
#9BA352
#818844
#676D36
#4C502A
#30321B
Base = 500Lightest = 50 · #F9F9F5Darkest = 950 · #30321B
:root {
  --brand-50: #F9F9F5;
  --brand-100: #F3F4EC;
  --brand-200: #E6E8D4;
  --brand-300: #D6DAB4;
  --brand-400: #C1C78F;
  --brand-500: #a7af5f;
  --brand-600: #9BA352;
  --brand-700: #818844;
  --brand-800: #676D36;
  --brand-900: #4C502A;
  --brand-950: #30321B;
  --brand: #a7af5f;
  --brand-ink: #000000;
}

Colors that work with #a7af5f

Not a palette — a role sheet. Each swatch answers one question you will hit while building the component.

Text on it#000000
Black wins here
Surface#F9FAF5
Tinted page background
Border#E1E4C9
Hairlines and dividers
Muted text#91994D
Captions on the surface
Accent#5A68B4
Second voice, not a rival
Dark variant#51552B
Hover, pressed, headers
Light variant#F6F6EE
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 #a7af5f

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

Works well for
  • Text and icons on dark surfaces
  • Charts, tags and secondary surfaces
  • Brand accents, badges and data highlights
Use with care
  • Text of any size on white — fails WCAG AA
  • 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#675FAF
Analogous left#AF8F5F
Analogous right#7FAF5F
Split-complement 1#5F7FAF
Split-complement 2#8F5FAF
Triadic 1#5FA7AF
Triadic 2#AF5FA7
Tetradic#5FAF8F

RGB percentages

Red65.5%
Green68.6%
Blue37.3%

CMYK percentages

Cyan4.6%
Magenta0.0%
Yellow45.7%
Key (black)31.4%

Color previews

#a7af5f text on a black background

contrast 8.94:1

Card sample

#a7af5f text on a white background

contrast 2.35:1

Card sample

CSS3 live lab

Text font color

The quick brown fox

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

Glowing headline

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

Soft neon halo

text-shadow: 0 0 14px rgba(167, 175, 95, 0.45);
Div box shadow
Elevated card
box-shadow: 0 12px 32px -8px rgba(167, 175, 95, 0.45);
Border & gradient
Gradient panel
border: 3px solid #a7af5f;
background: linear-gradient(135deg, #a7af5f, #72AF5F);

Monochromatic scale

Palettes built from #a7af5f

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.

#a7af5f 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.

#a7af5f, answered

What color is #a7af5f?

#a7af5f is a balanced soft yellow, closest to Dark Khaki (ΔE2000 5). It sits at 66° on the hue wheel with 33% saturation and 53% lightness, which reads as warm.

What is the RGB value of #a7af5f?

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

Is #a7af5f a light or a dark color?

It is a mid-tone. Relative luminance is 0.3970 and perceived brightness is 65%, so black text on it reaches 8.94:1.

Should I use black or white text on #a7af5f?

Black. It scores 8.94:1 against #a7af5f, versus 2.35:1 for white — AAA at any size.

What is the complementary color of #a7af5f?

#675FAF sits directly opposite on the wheel. Softer options are the split-complements #5F7FAF and #8F5FAF, which give the same contrast with far less vibration.

What colors go well with #a7af5f?

For interface work: #F9FAF5 as the surface, #E1E4C9 for borders, #91994D for secondary text, #5A68B4 as an accent and #51552B for hover and pressed states. For a palette, the analogous pair #AF8F5F and #7FAF5F stays calm, while #675FAF is the loudest partner.

What is #a7af5f in CMYK for printing?

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

Is #a7af5f warm or cool?

Warm — it scores 31 on a scale where 0 is the warmest orange and 100 the coolest azure. Nudged warmer it becomes #AF9A5F; nudged cooler, #8AB15C.

Work with #a7af5f in the Color Lab