#000000: pure black color codes, contrast and shades
By TechCompare · Updated · How we check
#000000 is rgb(0, 0, 0), with every channel off. White text on it scores 21.00:1, the highest ratio WCAG 2 allows.
Color Codes
- HEX
#000000 - RGB
rgb(0, 0, 0) - HSL
hsl(0, 0%, 0%) - OKLCH
oklch(0% 0 0)
Text on #000000
White Text
Aa
The quick brown fox jumps over the lazy dog.
21.00:1APCA Lc -107.9
- AA Normal (4.5:1)Pass
- AA Large (3:1)Pass
- AAA Normal (7:1)Pass
- AAA Large (4.5:1)Pass
Black Text
Aa
The quick brown fox jumps over the lazy dog.
1.00:1APCA Lc 0.0
- AA Normal (4.5:1)Fail
- AA Large (3:1)Fail
- AAA Normal (7:1)Fail
- AAA Large (4.5:1)Fail
WCAG 2 ratios are the same whichever color is the text, so they also hold for #000000 text on a white or black page. APCA is a newer method that isn't part of any WCAG standard, and a minus sign means light text on dark.
#000000 sets red, green and blue to zero, so the screen sends no light. On an OLED screen the pixels switch off entirely. You can also write it as #000 or the CSS name black. The cards above give its codes and test white and black text on it. Nothing is darker, so the shade scale below runs 8 steps up through gray.
Shades
Same hue and chroma in OKLCH, with even steps of lightness. Open any shade in the Color Picker.
Nearest Named Colors
CSS Name
black
#000000
ExactΔE OK 0.000Tailwind 4
black
#000000
ExactΔE OK 0.000Tailwind 3
black
#000000
ExactΔE OK 0.000
About #000000
Many dark themes avoid pure black. Material Design recommends a dark gray, #121212, for dark surfaces, because it can show shadows and lighter raised layers, and it's easier on the eyes than full black behind bright text. White text on #121212 still scores 18.73:1, far past AAA.
The shade scale gives you the same kind of surfaces. #060606 is barely apart from black, and #202020 reads as a dark gray that keeps white text at 16.29:1. White text passes AA up to #5F5F5F, and from #828282 on it needs dark text.
In print, #000000 converts to cmyk(0%, 0%, 0%, 100%), black ink only. Large black areas printed that way can look flat and gray, so printers often use rich black, which adds cyan, magenta and yellow under the black for a deeper tone.
Verdict
Use #000000 for text on light backgrounds, where it gets the full 21.00:1 against white. For dark mode backgrounds, consider a near black like #121212 or the second step of the shade scale instead, and save pure black for OLED focused designs where switching pixels off matters.
Click a shade to open it in the Color Picker.
More Color scenarios
Related guides
Frequently asked questions
What color is #000000?
Should I use #000000 for dark mode?
What's #000000 in CMYK?
Related tools
Contrast Checker
Check color contrast ratios for WCAG AA/AAA accessibility compliance.
Use toolJSON Formatter
Validate, format, and minify JSON. Browse it as a tree, run JSONPath queries, compare two documents, or validate against a JSON Schema.
Use toolAspect Ratio Visualizer
Visually compare width differences between 16:9, 21:9, and 32:9 monitors.
Use tool