HSL(215, 78%, 21%)
Blue — Blue color
Adjust Color
Color Information
Color Name
Blue
Color Family
Blue
Warm / Cool
🔵 Cool
Temperature
9000K
CSS Class
bg-[hsl(215,78%,21%)]
Color Conversions
| Format | Value | CSS Usage | |
|---|---|---|---|
| HSL | hsl(215, 78%, 21%) | color: hsl(215, 78%, 21%) | |
| HEX | #0C2F5F | color: #0C2F5F | |
| RGB | rgb(12, 47, 95) | color: rgb(12, 47, 95) | |
| CMYK | cmyk(87%, 51%, 0%, 63%) | — | |
| HSV | hsv(215, 87%, 37%) | — | |
| HWB | hwb(215 5% 63%) | color: hwb(215 5% 63%) | |
| OKLCH | oklch(0.3108 0.0943 257.61) | color: oklch(0.3108 0.0943 257.61) | |
| Lab | lab(19.79 7.74 -32.06) | color: lab(19.79 7.74 -32.06) | |
| LCH | lch(19.79 32.98 283.57) | color: lch(19.79 32.98 283.57) |
Color Theory
Accessibility (WCAG)
White text on color
Black text on color
Colored text
Contrast Ratios
AA Normal (4.5:1)
AA Large (3:1)
AAA Normal (7:1)
Best text on this color: white
Color Blindness Simulation
Protanopia (Red-blind)
#1B1B53 — rgb(27, 27, 83)
Deuteranopia (Green-blind)
#191751 — rgb(25, 23, 81)
Tritanopia (Blue-blind)
#0E4A48 — rgb(14, 74, 72)
Tints & Shades
CSS Code Snippets
background
background-color: hsl(215, 78%, 21%);
text
color: hsl(215, 78%, 21%);
border
border: 2px solid hsl(215, 78%, 21%);
gradient light
background: linear-gradient(to right, hsl(215, 78%, 41%), hsl(215, 78%, 21%));
gradient dark
background: linear-gradient(to right, hsl(215, 78%, 21%), hsl(215, 78%, 1%))
hex
background-color: #0C2F5F;
tailwind
bg-[hsl(215,78%,21%)]
box shadow
box-shadow: 0 4px 6px -1px hsl(215, 78%, 21%, 0.4);
css variable
--color-primary: hsl(215, 78%, 21%);
Related Colors
Use Cases for Blue
Frequently Asked Questions
What are all the color codes for HSL(215, 78%, 21%)?
HEX: #0C2F5F | RGB: rgb(12, 47, 95) | CMYK: 87%, 51%, 0%, 63% | HSV: 215°, 87%, 37%. Copy any format from the conversion table above.
What colors go well with #0C2F5F?
The complementary color is HSL(35, 78%, 21%). For a triadic harmony, use hues 215°, 335°, and 95°. For analogous combinations, try hues 185° and 245°. See the Color Harmony section above for complete palettes with previews.
How do I use HSL(215, 78%, 21%) in CSS?
As HSL: color: hsl(215, 78%, 21%); — As HEX: color: #0C2F5F; — As RGB: color: rgb(12, 47, 95); — Tailwind CSS: bg-[hsl(215,78%,21%)] — CSS variable: --color-primary: hsl(215, 78%, 21%);