Dark Violet
Hex #9400D3, rgb(148 0 211). A purple CSS named color.
Open in palette generatorDark Violet color codes
Click any value to copy it.
- HEX
- RGB
- HSL
- HSV
- HWB
- CMYK
- OKLCH
- OKLab
- Lab
- LCH
- CSS keyword
About Dark Violet
Dark Violet is a medium vivid purple with the hex code #9400D3. In RGB it is made of 148 red, 0 green and 211 blue; in HSL its hue is 282°, with 100% saturation and 41% lightness. Its perceptual lightness (OKLCH L) is 51.5%.
It is a CSS named color, so you can write "darkviolet" anywhere CSS accepts a color. Against white it has a contrast ratio of 6.56:1 and against black 3.20:1, so white text reads better on it and passes WCAG AA for normal text.
Tints, shades and tones
Dark Violet mixed step by step with white, black and middle gray (#808080).
Tints (with white)
Shades (with black)
Tones (with gray)
Dark Violet 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 Violet
Color harmonies rotate the hue in OKLCH and keep the lightness and chroma. Each color links to its closest named color.
Complementary
Triadic
Split complementary
Contrast and readability
WCAG 2 contrast of Dark Violet with white and black. The readable text color on Dark Violet is white.
On white6.56:1
- AA pass
- AA Large pass
- AAA fail
- UI 3:1 pass
APCA Lc 80
On black3.20:1
- AA fail
- AA Large pass
- AAA fail
- UI 3:1 pass
APCA Lc -22
Test any pair in the contrast checker.
Color blindness preview
How Dark Violet appears with each type of color vision deficiency (simulated with the Machado model).
- Protanopia#0058D8
- Deuteranopia#005FD0
- Tritanopia#8A4C7B
- Protanomaly#1F4DD5
- Deuteranomaly#3453D1
- Tritanomaly#9230B2
- Achromatopsia#5D5D5D
Colors similar to Dark Violet
The closest named colors by perceptual difference (OKLab).
Use Dark Violet in CSS and Tailwind
.dark-violet {
color: darkviolet; /* #9400D3 */
background-color: rgb(148 0 211);
border-color: oklch(51.5% 0.261 309.8);
}/* Tailwind CSS v4: bg-dark-violet-500, text-dark-violet-700... */
@theme {
--color-dark-violet-50: #FCF8FF;
--color-dark-violet-100: #F5E9FF;
--color-dark-violet-200: #EBD2FF;
--color-dark-violet-300: #DCAEFF;
--color-dark-violet-400: #C979FF;
--color-dark-violet-500: #BD4DFF;
--color-dark-violet-600: #B100FB;
--color-dark-violet-700: #9400D3;
--color-dark-violet-800: #750BA7;
--color-dark-violet-900: #5D0E85;
--color-dark-violet-950: #240037;
}
<!-- or the exact color, no config -->
<div class="bg-[#9400D3] text-[#FFFFFF]">…</div>