Blue HEX Code
The HEX code for pure blue is #0000FF. Blue is a primary color in the RGB model representing maximum intensity in the blue channel with no red or green.
Blue Color Values
| Format | Value |
|---|---|
| HEX | #0000FF |
| RGB | rgb(0, 0, 255) |
| HSL | hsl(240, 100%, 50%) |
| CMYK | C:100 M:100 Y:0 K:0 |
Blue Shades and Variations
| Shade | HEX | Description |
|---|---|---|
| Light Blue | #ADD8E6 | Soft, calming |
| Sky Blue | #87CEEB | Bright, cheerful |
| Blue | #0000FF | Pure blue |
| Royal Blue | #4169E1 | Rich, elegant |
| Navy Blue | #000080 | Deep, professional |
| Steel Blue | #4682B4 | Gray-tinted |
| Teal | #008080 | Green-tinted |
Blue in Design
Blue conveys:
- Trust: Banks, insurance, healthcare
- Calm: Relaxation, meditation
- Professionalism: Corporate, business
- Technology: Tech companies
CSS Usage
``css
.primary-button {
background-color: #0000FF;
/* Or using the name */
background-color: blue;
}
`
Brand Blues
| Brand | HEX |
|---|---|
| #1877F2 | |
| #1DA1F2 | |
| #0A66C2 | |
| IBM | #0530AD |
Blue in Every Format
| Format | Value |
|---|---|
| HEX | #0000FF |
| RGB | rgb(0, 0, 255) |
| HSL | hsl(240, 100%, 50%) |
| CMYK | cmyk(100%, 100%, 0%, 0%) |
| Nearest Tailwind | blue-700 (#1D4ED8) |
About This Colour
Blue is #0000FF, pure blue at full intensity. It is the default link colour of the web (though browsers now render visited links closer to #551A8B), and the most common primary in enterprise design systems.
Will It Pass Contrast?
| Combination | Ratio | WCAG |
|---|---|---|
| Blue text on white | 8.59:1 | AAA |
| Blue text on black | 2.44:1 | fails |
| White text on blue | 8.59:1 | AAA |
WCAG AA needs 4.5:1 for body text and 3:1 for text above 18pt or 14pt bold. Blue passes on white, so it is safe for body text on a light background.Building a Palette Around It
| Role | Colour |
|---|---|
| Lighter (+20%) | #6666ff |
| Base | #0000FF |
| Darker (−20%) | #000099 |
| Complementary | #ffff00 |
| Triadic | #ff0000, #00ff00 |
Tints (toward white): #4040ff, #8080ff, #bfbfffShades (toward black): #0000bf, #000080, #000040
Using It
`css
:root {
--blue: #0000ff;
--blue-light: #6666ff;
--blue-dark: #000099;
}
.badge {
background: var(--blue);
color: #000;
}
`
Define the colour once as a custom property rather than repeating the hex. When the brand
changes — and it will — you edit one line instead of grepping a stylesheet.
A Full Ramp From This Colour
Design systems settle on a 50–900 scale because it covers backgrounds, borders, text and
states without anyone reaching outside the palette. Mixing toward white and black rather
than adjusting HSL lightness keeps more of the hue's character:
| Step | Colour | Contrast on white | Safe for |
|---|---|---|---|
| 50 | #F5F9FF | 1.06:1 | backgrounds and fills |
| 100 | #EBF3FE | 1.12:1 | backgrounds and fills |
| 200 | #CEE0FD | 1.34:1 | backgrounds and fills |
| 300 | #B1CDFB | 1.62:1 | backgrounds and fills |
| 400 | #76A8F9 | 2.40:1 | backgrounds and fills |
| 500 | #3B82F6 | 3.68:1 | large text, borders |
| 600 | #326FD1 | 4.85:1 | body text on white |
| 700 | #295BAC | 6.59:1 | body text on white |
| 800 | #204887 | 8.98:1 | body text on white |
| 900 | #183462 | 12.31:1 | body text on white |
The contrast column is the one that decides usage. Steps below 3:1 cannot carry text at
any size and belong in fills and dividers; steps at 4.5:1 and above are safe for body copy.Adjusting It
Base colour in HSL is hsl(217, 91%, 60%). Two useful moves:
`css
/* +10% lightness, same hue */
--lighter: #6da2f8;
/* −10% lightness */
--darker: #0b64f4;
``
Raising lightness also drops perceived saturation, so a lightened colour reads greyer than its numbers suggest. Adding 5–10% saturation alongside every 20% of lightness keeps the ramp looking like one hue rather than a fade to grey.