Khaki color (#F0E68C)
Khaki is one of the 148 CSS named colors. Use the keyword khaki
anywhere CSS accepts a color, or its hex code #F0E68C, which is rgb(240, 230, 140) in RGB.
It is a very light, moderately saturated warm color with a hue angle of 54° on the HSL color wheel and a perceived lightness of 91% in OKLCH. On a khaki background, black text gives the higher contrast at 16.40:1, which passes WCAG AA for normal text.
Khaki color codes
| CSS name | khaki |
|
|---|---|---|
| HEX | #F0E68C |
|
| HEX (8-digit) | #F0E68CFF |
|
| RGB | rgb(240, 230, 140) |
|
| HSL | hsl(54, 77%, 75%) |
|
| HSV / HSB | hsv(54, 42%, 94%) |
|
| OKLCH | oklch(91.3% 0.1119 102.8) |
|
| CMYK | cmyk(0%, 4.2%, 41.7%, 5.9%) |
Contrast with white and black
WCAG 2 contrast ratios and APCA lightness contrast (Lc) for khaki used as text and as a background.
Tints and shades of khaki
Tints mix khaki with white; shades mix it with black, in 10% steps. Click a swatch to copy it, or build custom scales in the tint & shade generator.
Tints
Shades
Colors that go with khaki
Harmonies calculated on the HSL color wheel. Explore more in the color scheme generator.
Complementary
Analogous
Triadic
Split-Complementary
Khaki with color blindness
Approximately how khaki appears with each type of color vision deficiency. Test full designs with the color blindness simulator.
Using khaki in CSS
.element {
color: khaki;
background-color: #f0e68c;
border-color: rgb(240 230 140 / 50%);
outline-color: oklch(91.3% 0.1119 102.8);
}Similar named colors
See all shades of yellow or browse every CSS color name.