Black gradients
Black gradients add depth to dark designs without the flat, heavy look of pure black. Most run from black into a charcoal, a dark gray or a deep tinted color such as navy, plum or forest green, which gives dark mode screens, hero sections and product shots a subtle sense of light. White text reads well across nearly every black gradient, but watch gradients that fade all the way into mid gray, where contrast drops. A black-to-transparent gradient is also a common overlay that keeps text readable on top of photos. Each gradient below shows its CSS, the text color that reads best across it and its worst-case contrast. Open any of them in the gradient generator to adjust it.
6 black gradients with CSS code
- Charcoal Fade
Charcoal Fade
background: linear-gradient(180deg, #000000 0%, #36454F 100%);White text passes AA, at worst 9.9:1.
- Midnight Black
Midnight Black
background: linear-gradient(135deg, #000000 0%, #1E2F4A 100%);White text passes AA, at worst 13.45:1.
- Graphite
Graphite
background: linear-gradient(160deg, #111113 0%, #4B4B4B 100%);White text passes AA, at worst 8.72:1.
- Black Plum
Black Plum
background: linear-gradient(135deg, #0B0B0C 0%, #3E2C34 100%);White text passes AA, at worst 13:1.
- Black Forest
Black Forest
background: linear-gradient(180deg, #000000 0%, #14281D 50%, #2F5D50 100%);White text passes AA, at worst 7.49:1.
- Onyx Sheen
Onyx Sheen
background: linear-gradient(90deg, #1B1B1B 0%, #353839 50%, #1B1B1B 100%);White text passes AA, at worst 11.82:1.