blue blue #0000ff
blue is #0000ff in hexadecimal, rgb(0, 0, 255) in decimal and hsl(240, 100, 50) in HSL. This page lists its harmonies, lightness steps and contrast against black and white — all copyable.
HEX · RGB · HSL
| HEX | #0000ff |
| RGB | rgb(0, 0, 255) |
| HSL | hsl(240, 100%, 50%) |
Harmonies
Complementary
Analogous
#0080ff#8000ffSplit complementary
#ff8000#80ff00Tints & shades
Accessibility
| vs #ffffff | 8.59:1 |
| vs #000000 | 2.44:1 |
| Suggested text color | #ffffff · 8.59:1 · WCAG AAA |
Similar named colors
FAQ
What is the HEX code for blue?
blue is #0000ff in hex, rgb(0, 0, 255) in decimal and hsl(240, 100%, 50%) in HSL. In CSS you can write either color: blue; or color: #0000ff; — they are equivalent.
What colors go with blue?
The complementary #ffff00 gives the strongest contrast, the analogous pair #0080ff / #8000ff is the safest, and the triad #ff0000 / #00ff00 adds more tension. All three are derived from the 240° hue of #0000ff.
Does #0000ff read better on white or black?
Its contrast is 8.59:1 against white and 2.44:1 against black. Use #ffffff text on it — that gives 8.59:1, which meets WCAG AAA.
Is a named color different from a hex color?
No. CSS named colors are just syntactic sugar for standard six-digit hex values; browsers resolve them to identical results in every modern engine.