CSS named color
Tan #D2B48C
Tan (CSS keyword tan) has the hex code #D2B48C and the RGB value rgb(210, 180, 140): a light, muted tan.
Tan (#d2b48c) takes its name from tanned leather and the tanbark used in tanning. With red, it is one of the two shortest CSS color names.
Color codes for Tan
| CSS keyword | tan |
|---|---|
| HEX | #D2B48C |
| RGB | rgb(210, 180, 140) |
| HSL | hsl(34, 44%, 69%) |
| HWB | hwb(34 55% 18%) |
| OKLCH | oklch(78.6% 0.064 74.6) |
| CMYK (naive, no ICC profile) | cmyk(0%, 14%, 33%, 18%) |
| Decimal | 13,808,780 |
| Hue family | Browns and tans |
Contrast and accessibility
On tan, black text has a contrast ratio of 10.64:1 and passes AAA at any text size; white text reaches 1.97:1.
WCAG 2.2 contrast ratios (success criteria 1.4.3 and 1.4.6: AA needs 4.5:1 for normal text and 3:1 for large text, AAA needs 7:1 and 4.5:1). APCA Lc is the lightness contrast from the APCA-W3 0.0.98G model proposed for WCAG 3; a higher absolute value is more readable, and Lc 75 is its suggested minimum for body text.
| Pair | Ratio | AA | AA large | AAA | AAA large | APCA Lc |
|---|---|---|---|---|---|---|
| Black text on tan | 10.64:1 | Pass | Pass | Pass | Pass | 65.9 |
| White text on tan | 1.97:1 | Fail | Fail | Fail | Fail | −42.4 |
| Tan text on white | 1.97:1 | Fail | Fail | Fail | Fail | 38.0 |
| Tan text on black | 10.64:1 | Pass | Pass | Pass | Pass | −64.4 |
Tints and shades
Each step mixes tan with white (tints) or black (shades) in gamma-encoded sRGB, the same result as color-mix(in srgb, tan, white 25%) in CSS.
Tints (mixed with white)
- 5%
#d4b892 - 15%
#d9bf9d - 25%
#ddc7a9 - 35%
#e2ceb4 - 45%
#e6d6c0 - 55%
#ebddcb - 65%
#efe5d7 - 75%
#f4ece2 - 85%
#f8f4ee - 95%
#fdfbf9
Shades (mixed with black)
- 5%
#c8ab85 - 15%
#b39977 - 25%
#9e8769 - 35%
#89755b - 45%
#74634d - 55%
#5e513f - 65%
#4a3f31 - 75%
#352d23 - 85%
#201b15 - 95%
#0b0907
Color harmonies
Rotating the hue in OKLCH while keeping lightness and chroma, tan's complementary color is #9EBCE2 (close to lightsteelblue), its analogous colors are #DDAD98 and #BFBC8D, and its triadic partners are #88C7C6 and #C9AED6. For text on top, black gives the higher contrast.
| Harmony | Rotation | Color |
|---|---|---|
| Complementary | +180° | #9ebce2 |
| Analogous | −30°, +30° | #ddad98#bfbc8d |
| Triadic | +120°, +240° | #88c7c6#c9aed6 |
| Split-complementary | +150°, +210° | #8dc3d8#b4b4e1 |
Computed in OKLCH: the hue is rotated by 180° (complementary), ±30° (analogous), ±120° (triadic) and 180° ±30° (split-complementary) while lightness and chroma stay fixed. Results that fall outside sRGB are brought back with the CSS Color 4 gamut mapping algorithm. Because this uses OKLCH, the values differ from tools that rotate hue in HSL, but every color keeps the same perceived lightness.
Warm or cool?
Tan is a warm color: its hue is 34° on the HSL wheel, in the red, orange and yellow range (0° to about 70°, plus reds above 330°) that is conventionally called warm.
Nearest named and Tailwind colors
Distance is ΔE OK, the Euclidean distance in OKLab multiplied by 100. Values under about 2 are hard to tell apart side by side.
Nearest CSS named colors
| Color | HEX | ΔE OK |
|---|---|---|
| burlywood | #deb887 | 2.3 |
| darkkhaki | #bdb76b | 5.6 |
| sandybrown | #f4a460 | 6.7 |
Nearest Tailwind v4 colors
| Color | HEX | ΔE OK |
|---|---|---|
| olive-400 | #abab9c | 6.8 |
| orange-300 | #ffb86a | 8.3 |
| taupe-400 | #aba09c | 8.9 |
Code snippets
.element {
color: tan;
background-color: #d2b48c;
border-color: rgb(210 180 140);
outline-color: oklch(78.6% 0.064 74.6);
}<div class="bg-[#d2b48c] text-black">...</div>
/* or register it once in your CSS (Tailwind v4) */
@theme {
--color-tan: #d2b48c;
}
/* then use bg-tan, text-tan, border-tan */import SwiftUI
extension Color {
static let tan = Color(red: 0.824, green: 0.706, blue: 0.549)
}import androidx.compose.ui.graphics.Color
val Tan = Color(0xFFD2B48C)import 'package:flutter/material.dart';
const tan = Color(0xFFD2B48C);<!-- res/values/colors.xml -->
<color name="tan">#D2B48C</color>Frequently asked questions
- What is the hex code for tan?
- The hex code for tan is #D2B48C. The same color is rgb(210, 180, 140), hsl(34, 44%, 69%) and oklch(78.6% 0.064 74.6), and in CSS you can also write the keyword tan directly.
- Is tan a warm or cool color?
- Tan is a warm color: its hue is 34° on the HSL wheel, in the red, orange and yellow range (0° to about 70°, plus reds above 330°) that is conventionally called warm.
- What colors go with tan?
- Rotating the hue in OKLCH while keeping lightness and chroma, tan's complementary color is #9EBCE2 (close to lightsteelblue), its analogous colors are #DDAD98 and #BFBC8D, and its triadic partners are #88C7C6 and #C9AED6. For text on top, black gives the higher contrast.
- Can you use white text on tan?
- White text on tan has a contrast ratio of 1.97:1, which fails AA even for large text under WCAG 2.2. Black text reaches 10.64:1 and passes both AA and AAA. In APCA terms that is Lc −42.4 for white and Lc 65.9 for black.
- What is the RGB value of tan?
- Tan is rgb(210, 180, 140): red 210, green 180 and blue 140 on the 0 to 255 scale, or 82.4%, 70.6% and 54.9%. As a decimal integer it is 13808780.
Last reviewed by Arielton Oberek.