Dark Slate Gray
Hex #2F4F4F, rgb(47 79 79). A gray or black CSS named color.
Open in palette generatorDark Slate Gray color codes
Click any value to copy it.
- HEX
- RGB
- HSL
- HSV
- HWB
- CMYK
- OKLCH
- OKLab
- Lab
- LCH
- CSS keyword
About Dark Slate Gray
Dark Slate Gray is a dark neutral gray with the hex code #2F4F4F. In RGB it is made of 47 red, 79 green and 79 blue; in HSL its hue is 180°, with 25% saturation and 25% lightness. Its perceptual lightness (OKLCH L) is 40.3%.
It is a CSS named color, so you can write "darkslategray" or "darkslategrey" anywhere CSS accepts a color. Against white it has a contrast ratio of 8.93:1 and against black 2.35:1, so white text reads better on it and passes WCAG AA for normal text.
Also written as Dark Slate Grey: CSS treats both spellings as the same color.
Tints, shades and tones
Dark Slate Gray mixed step by step with white, black and middle gray (#808080).
Tints (with white)
Shades (with black)
Tones (with gray)
Dark Slate Gray 50-950 scale
A Tailwind-style scale built in OKLCH; the original color sits on the step with the closest lightness.
Colors that go with Dark Slate Gray
Color harmonies rotate the hue in OKLCH and keep the lightness and chroma. Each color links to its closest named color.
Complementary
Split complementary
Contrast and readability
WCAG 2 contrast of Dark Slate Gray with white and black. The readable text color on Dark Slate Gray is white.
On white8.93:1
- AA pass
- AA Large pass
- AAA pass
- UI 3:1 pass
APCA Lc 90
On black2.35:1
- AA fail
- AA Large fail
- AAA fail
- UI 3:1 fail
APCA Lc -12
Test any pair in the contrast checker.
Color blindness preview
How Dark Slate Gray appears with each type of color vision deficiency (simulated with the Machado model).
- Protanopia#4B4C4F
- Deuteranopia#45484F
- Tritanopia#22514F
- Protanomaly#454C4F
- Deuteranomaly#414A4F
- Tritanomaly#2A504F
- Achromatopsia#4A4A4A
Colors similar to Dark Slate Gray
The closest named colors by perceptual difference (OKLab).
Use Dark Slate Gray in CSS and Tailwind
.dark-slate-gray {
color: darkslategray; /* #2F4F4F */
background-color: rgb(47 79 79);
border-color: oklch(40.3% 0.038 195.8);
}/* Tailwind CSS v4: bg-dark-slate-gray-500, text-dark-slate-gray-700... */
@theme {
--color-dark-slate-gray-50: #F7FBFB;
--color-dark-slate-gray-100: #E7F1F0;
--color-dark-slate-gray-200: #CFE2E1;
--color-dark-slate-gray-300: #AACCCB;
--color-dark-slate-gray-400: #7AAEAE;
--color-dark-slate-gray-500: #5C9B9B;
--color-dark-slate-gray-600: #4B8888;
--color-dark-slate-gray-700: #3E7171;
--color-dark-slate-gray-800: #355E5E;
--color-dark-slate-gray-900: #2F4F4F;
--color-dark-slate-gray-950: #061A1A;
}
<!-- or the exact color, no config -->
<div class="bg-[#2F4F4F] text-[#FFFFFF]">…</div>