#0000FF: pure blue color codes, contrast and shades
By TechCompare · Updated · How we check
#0000FF is rgb(0, 0, 255), the CSS color blue and the blue primary of sRGB. It's a dark color: white text scores 8.59:1, black only 2.44:1.
Color Codes
- HEX
#0000FF - RGB
rgb(0, 0, 255) - HSL
hsl(240, 100%, 50%) - OKLCH
oklch(45.2% 0.3132 264.05)
Text on #0000FF
White Text
Aa
The quick brown fox jumps over the lazy dog.
8.59:1APCA Lc -90.7
- 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.
2.44:1APCA Lc 18.2
- 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 #0000FF 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.
#0000FF turns the blue channel all the way up and leaves red and green off. Even at full strength it's the darkest of the three primaries, at an OKLCH lightness of 45.2%, against 62.8% for pure red and 86.64% for pure green. Your eyes are least sensitive to blue, so it adds the least brightness. The cards above give its codes and test white and black text on it. Below are 4 lighter and 4 darker shades.
Shades
Same hue and chroma in OKLCH, with even steps of lightness. Open any shade in the Color Picker.
Nearest Named Colors
CSS Name
blue
#0000FF
ExactΔE OK 0.000Tailwind 4
blue-700
oklch(48.8% 0.243 264.376)
Not CloseΔE OK 0.079Tailwind 3
blue-700
#1D4ED8
Not CloseΔE OK 0.103
About #0000FF
The classic blue link isn't quite #0000FF. The HTML spec's default link color is #0000EE, a touch darker, and visited links turn #551A8B. Both pass AAA on a white page, at 9.40:1 and 11.01:1.
The trouble is dark backgrounds. Blue text on white scores 8.59:1, but blue text on black gets only 2.44:1 and fails at every size. For links in a dark theme, go two steps up the shade scale: #6A9DFF scores 7.88:1 against black.
No Tailwind color matches it. The nearest in Tailwind 4, blue-700, sits 0.079 away in OKLab, a softer blue.
Verdict
Use #0000FF for links and buttons on light backgrounds, with white labels. Keep it away from dark backgrounds as text.
For a lighter blue that still takes white text, #2866FF is the limit, at 4.74:1. The darker steps all keep white text past AAA. Click a shade to open it in the Color Picker.
More Color scenarios
Related guides
Frequently asked questions
What color is #0000FF?
Is #0000FF the default link color?
Does #0000FF work on a dark background?
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