HSL(235, 70%, 40%)

Blue — Blue color

Adjust Color

Color Information

Color Name

Blue

Color Family

Blue

Warm / Cool

🔵 Cool

Temperature

9000K

CSS Class

bg-[hsl(235,70%,40%)]

Color Conversions

Format Value CSS Usage
HSL hsl(235, 70%, 40%) color: hsl(235, 70%, 40%)
HEX #1F2BAD color: #1F2BAD
RGB rgb(31, 43, 173) color: rgb(31, 43, 173)
CMYK cmyk(82%, 75%, 0%, 32%)
HSV hsv(235, 82%, 68%)
HWB hwb(235 12% 32%) color: hwb(235 12% 32%)
OKLCH oklch(0.3872 0.2012 268.9) color: oklch(0.3872 0.2012 268.9)
Lab lab(26.83 43 -69.42) color: lab(26.83 43 -69.42)
LCH lch(26.83 81.66 301.77) color: lch(26.83 81.66 301.77)

Color Theory

Complementary

Triadic

Analogous

Tetradic (Square)

Split-Complementary

Accessibility (WCAG)

White text on color

Black text on color

Color on white bg

Colored text

Contrast Ratios

vs White 10.46:1
vs Black 2.01:1

AA Normal (4.5:1)

on White: PASS ✓ on Black: FAIL ✗

AA Large (3:1)

on White: PASS ✓ on Black: FAIL ✗

AAA Normal (7:1)

on White: PASS ✓

Best text on this color: white

Color Blindness Simulation

Protanopia (Red-blind)

#24248E — rgb(36, 36, 142)

Deuteranopia (Green-blind)

#242386 — rgb(36, 35, 134)

Tritanopia (Blue-blind)

#20756F — rgb(32, 117, 111)

Tints & Shades

Tints (Lighter →)

← Shades (Darker)

Saturation (0% → 100%)

CSS Code Snippets

background

background-color: hsl(235, 70%, 40%);

text

color: hsl(235, 70%, 40%);

border

border: 2px solid hsl(235, 70%, 40%);

gradient light

background: linear-gradient(to right, hsl(235, 70%, 60%), hsl(235, 70%, 40%));

gradient dark

background: linear-gradient(to right, hsl(235, 70%, 40%), hsl(235, 70%, 20%))

hex

background-color: #1F2BAD;

tailwind

bg-[hsl(235,70%,40%)]

box shadow

box-shadow: 0 4px 6px -1px hsl(235, 70%, 40%, 0.4);

css variable

--color-primary: hsl(235, 70%, 40%);

Related Colors

Use Cases for Blue

Corporate branding Trust signals Tech products Social media Primary buttons

Frequently Asked Questions

What are all the color codes for HSL(235, 70%, 40%)?

HEX: #1F2BAD | RGB: rgb(31, 43, 173) | CMYK: 82%, 75%, 0%, 32% | HSV: 235°, 82%, 68%. Copy any format from the conversion table above.

What colors go well with #1F2BAD?

The complementary color is HSL(55, 70%, 40%). For a triadic harmony, use hues 235°, 355°, and 115°. For analogous combinations, try hues 205° and 265°. See the Color Harmony section above for complete palettes with previews.

How do I use HSL(235, 70%, 40%) in CSS?

As HSL: color: hsl(235, 70%, 40%); — As HEX: color: #1F2BAD; — As RGB: color: rgb(31, 43, 173); — Tailwind CSS: bg-[hsl(235,70%,40%)] — CSS variable: --color-primary: hsl(235, 70%, 40%);