100% free no uploads no sign-up

cobalt blue color code

The hex code for cobalt blue is #0047AB, which is rgb(0, 71, 171) in RGB and cmyk(100%, 58%, 0%, 33%) in CMYK. It's a dark, vivid blue. There is no official standard for cobalt blue; #0047AB is the value most colour references use.

#0047ABcobalt blue
White text: 8.43:1 ✓ AABlack text: 2.48:1 ✗Nearest name: cobalt blue

Move the sliders to find a lighter, darker or softer cobalt blue; the codes update as you go.

Cobalt Blue colour codes

HEX#0047AB
RGBrgb(0, 71, 171)
HSLhsl(215, 100%, 34%)
HSV / HSBhsv(215, 100%, 67%)
CMYKcmyk(100%, 58%, 0%, 33%)
Decimal18347

About cobalt blue

Cobalt Blue sits at a hue of 215° on the colour wheel, with 100% saturation and 34% lightness. That makes it a cool colour: cool colours feel calm and steady and appear to recede, so they work well for large areas.

Named after the cobalt-based blue pigment used in paints and ceramics.

For text, white reads better on cobalt blue. Cobalt Blue as text on a white background has a contrast ratio of 8.43:1, which passes the WCAG AA rule for body text (4.5:1). On black it is 2.48:1, which fails AA for body text.

Tints and shades of cobalt blue

Tints mix cobalt blue with white and shades mix it with black, in 10% steps. They're the easiest way to get lighter backgrounds and darker hover or text colours that still match.

#E6EDF7#CCDAEE#B3C8E6#99B5DD#80A3D5#6691CD#4D7EC4#336CBC#1A59B3
cobalt blue #0047AB
#00409A#003989#003278#002B67#002456#001C44#001533#000E22#000711

Colours that go with cobalt blue

Complementary — opposite on the colour wheel: maximum contrast

#0047AB#AB6400

Analogous — neighbours 30° either side: calm and natural

#009DAB#0047AB#0E00AB

Triadic — three hues 120° apart: lively but balanced

#0047AB#AB0047#47AB00

Split complementary — the two neighbours of the complement: contrast with less tension

#0047AB#AB0E00#9DAB00

Tetradic — four hues 90° apart: rich, use one as the main colour

#0047AB#AB009D#AB6400#00AB0E

Cobalt Blue text contrast

CombinationRatioAA normal (4.5:1)AA large (3:1)AAA (7:1)
cobalt blue on white8.43:1passpasspass
cobalt blue on black2.48:1failfailfail

Check cobalt blue against any other colour in the contrast checker.

How cobalt blue looks with colour blindness

Simulated with the Machado et al. (2009) model for the complete loss of one type of cone cell. Colour vision deficiency affects roughly 1 in 12 men and 1 in 200 women, most often as red-green colour blindness.

normal #0047ABprotanopia #0056AEdeuteranopia #0046A9tritanopia #006172

Use cobalt blue in code

.cobalt-blue {
  color: #0047ab;
  background-color: #0047ab;
  border-color: rgb(0, 71, 171);
}

Frequently asked questions

What is the hex code for cobalt blue?

#0047AB is the most widely used value for cobalt blue. There's no official standard, so paint, fabric and brand swatches called cobalt blue can differ slightly; use the hex code to match it exactly on screen.

What is cobalt blue in RGB, HSL and CMYK?

RGB: rgb(0, 71, 171). HSL: hsl(215, 100%, 34%). CMYK: cmyk(100%, 58%, 0%, 33%). CMYK is a simple conversion for reference; for professional printing, ask your printer for a matching ink or Pantone swatch.

What colours go with cobalt blue?

Its complementary colour is #AB6400 (close to ochre), which gives the strongest contrast. For a calmer look, use the analogous colours #009DAB and #0E00AB, or the triadic pair #AB0047 and #47AB00. Tints and shades of cobalt blue itself always work together.

Is cobalt blue a warm or cool colour?

Cobalt Blue has a hue of 215°, which makes it cool.

Should I use black or white text on cobalt blue?

White. Black text on cobalt blue has a contrast ratio of 2.48:1 and white text has 8.43:1. WCAG asks for at least 4.5:1 for normal text and 3:1 for large text.

Is cobalt blue a CSS colour name?

No. Cobalt Blue isn't one of the named colours built into CSS, so write it as a hex code: color: #0047ab;

Colours similar to cobalt blue