Khaki Color Codes
Khaki is a very light, saturated yellow with the hex code #F0E68C, RGB values of 240, 230, 140 and an HSL value of hsl(54, 77%, 75%).
| HEX | #F0E68C |
|---|---|
| RGB | 240, 230, 140 |
| HSL | hsl(54, 77%, 75%) |
| HSV | 54°, 42%, 94% |
| CMYK | 0%, 4%, 42%, 6% |
| LAB | 90.33, -9.01, 44.98 |
| CIELCHuv | 90.33, 61.92, 79.93° |
- Nearest Pantone
- PMS 127 C ΔE 3.5 · approximate
- Nearest CSS name
-
khakiΔE 0.0
Source CSS Color Module Level 4 keyword 'Khaki'
Khaki Color Hex Code
The Khaki color hex code is #F0E68C. Those six digits are three pairs, F0 for red, E6 for green and 8C for blue, which is the same triplet a browser reads from the CSS value below.
#F0E68C
Khaki Color RGB Code
The Khaki RGB code is rgb(240, 230, 140). Red carries the most light at 240 of 255, which is what puts this color where it sits on the wheel.
rgb(240, 230, 140)
Khaki Color HSV Code
The Khaki HSV code is 54°, 42%, 94%. Read it as a hue of 54 degrees, 42% saturation and 94% value, which is the form most color pickers use because moving one number changes one thing.
54°, 42%, 94%
Khaki Color CIELChuv Code
The Khaki CIELCHuv code is 90.33, 61.92, 79.93°. Unlike hex or RGB this one is perceptual: lightness 90 means light to the eye rather than to the screen, and chroma 62 is how far it sits from grey.
90.33, 61.92, 79.93°
Tonal scale
What are Khaki Color Palettes?
A shade mixes toward black, a tint toward white, a tone toward grey. Every step keeps the hue and is copy-ready.
Shades, toward black
Tints, toward white
Tones, toward grey
Palettes
What are Khaki Color Palette Codes?
Each of these is a hue rotation from #F0E68C. They are generated, not curated, so they are exact.
Complementary
Directly opposite sits #8C96F0, a mid-tone, saturated blue. No other pairing separates two hues further, so this is the one to reach for when a single element has to win attention. Both are saturated, so give the complement much less area than the base or the two will fight.
Analogous
#F0B48C and #C8F08C sit 30 degrees either side. All three share most of their hue, so the set reads as one family instead of three separate decisions. Good for backgrounds and for state variations that should not announce themselves.
Triadic
#8CF0E6 and #E68CF0 complete an even 120 degree split. Three fully independent hues, so one has to lead: keep this base dominant and let the other two appear in small quantities.
Split-complementary
Instead of the direct complement, this takes the two hues either side of it: #8CC8F0 and #B48CF0. Almost the same contrast, without the edge shimmer a true complementary pair produces at high saturation.
Tetradic
Two complementary pairs forming a rectangle: this base with #8C96F0, and #8CF0B4 with #F08CC8. The richest of the five and the hardest to balance, so treat the darkest of the four as the lead and hold the other three well back.
Accessibility
Contrast checker: is Khaki accessible?
Measured against white and against black, with a separate verdict for each element type. Small text, large text and UI components have different thresholds, so one pass or fail for the whole color would be wrong roughly a third of the time.
White background
1.28:11.28
contrast ratio on white background
| Element | AA | AAA |
|---|---|---|
| Small text needs 4.5:1 / 7:1 | Fails | Fails |
| Large text needs 3:1 / 4.5:1 | Fails | Fails |
| UI component needs 3:1 | Fails | n/a |
Black background
16.40:116.40
contrast ratio on black background
| Element | AA | AAA |
|---|---|---|
| Small text needs 4.5:1 / 7:1 | Passes | Passes |
| Large text needs 3:1 / 4.5:1 | Passes | Passes |
| UI component needs 3:1 | Passes | n/a |
At 1.28:1 against white, Khaki is a fill color rather than a text color. Use it for surfaces, borders and large display type, and set the copy in ink. Text placed on it should be black, which gives 16.40:1.
Color vision
How Khaki looks with color blindness
Around 300 million people see color differently from the way it is specified. Each card shows the actual color beside how it appears, and how common that form of vision is.
Protanopia
About 1% of men#ECECA8
Khaki shifts noticeably here. ΔE 12.1
No working red cones. Reds darken sharply and drift toward the same muddy olive as green.
Deuteranopia
About 1% of men#ECEDAE
Khaki shifts noticeably here. ΔE 14.6
No working green cones. With the milder deuteranomaly at nearer 6% of men, this is by far the most common form, and the one worth designing around.
Tritanopia
About 1 in 10,000#F0BABE
Khaki changes substantially here. ΔE 50.0
No working blue cones. Blues shift toward green and yellows toward pink. Rare, and unlike the others it is not sex-linked, so it affects men and women equally.
Achromatopsia
About 1 in 30,000#E3E3E3
Khaki changes substantially here. ΔE 45.9
No color vision at all. Also a fair proxy for how the color survives a greyscale print or a failing screen.
To a deuteranope, the most common form, Khaki reads as #ECEDAE. That is a shift of ΔE 14.6, so it is a different color to roughly one man in sixteen. The widest shift is under tritanopia, at ΔE 50.0. The rule this leads to needs no simulator: never let color be the only thing carrying a message. Add a label, an icon, or a clear difference in lightness, and the problem disappears for everyone.
Snippets
Using Khaki in code
:root {
--khaki: #F0E68C;
}
.example {
color: var(--khaki);
}
// tailwind.config.js
theme: {
extend: {
colors: {
'khaki': '#F0E68C',
},
},
}
// SwiftUI takes 0–1 components, not 0–255.
let khaki = Color(
red: 0.941,
green: 0.902,
blue: 0.549
)
<!-- res/values/colors.xml -->
<color name="khaki">#F0E68C</color>
// Flutter wants ARGB: FF for full opacity, then the hex.
const khaki = Color(0xFFF0E68C);