#0C0C31 color
The hex color #0C0C31 is a very dark, moderate blue.
In the RGB color model it is made of 4.7% red, 4.7% green and 19.2% blue (12, 12, 49).
Its hue angle is 240°, with 61% saturation and 12% lightness. For print, the CMYK equivalent is 76% cyan, 76% magenta, 0% yellow and 81% black.
The closest named color is Infinite Night (#071037), a difference of 1.8 ΔE, which is barely visible.
White text is the more readable choice on this background (contrast 18.88:1).
#0C0C31 color codes
| HEX | #0C0C31 | |
|---|---|---|
| RGB | rgb(12, 12, 49) | |
| RGB percent | rgb(4.7%, 4.7%, 19.2%) | |
| HSL | hsl(240, 61%, 12%) | |
| HSV / HSB | hsv(240, 76%, 19%) | |
| CMYK | cmyk(76%, 76%, 0%, 81%) | |
| CIE LAB | lab(5.08, 12.39, -23.85) | |
| CIE LCH | lch(5.08, 26.88, 297.44) | |
| CIE XYZ | xyz(0.837, 0.563, 2.97) | |
| Decimal | 789553 | |
| Short hex | None (no 3-digit form) |
Color harmonies
Colors that go with #0C0C31, based on their position on the color wheel.
Complementary
The color opposite on the color wheel (180°). Strongest contrast.
Analogous
Neighbors 30° either side. Calm, natural combinations.
Split complementary
The two colors next to the complement (150° and 210°).
Triadic
Three colors evenly spaced, 120° apart.
Tetradic (square)
Four colors 90° apart.
Shades, tints and tones
Shades (darker, mixed with black)
Tints (lighter, mixed with white)
Tones (mixed with gray)
Contrast and accessibility
| Text on #0C0C31 | Ratio | AA | AAA | AA large |
|---|---|---|---|---|
| Sample text | 1.11:1 | Fail | Fail | Fail |
| Sample text | 18.88:1 | Pass | Pass | Pass |
| #0C0C31 as text on | Ratio | AA | AAA | AA large |
|---|---|---|---|---|
| Sample text | 18.88:1 | Pass | Pass | Pass |
| Sample text | 1.11:1 | Fail | Fail | Fail |
WCAG 2 asks for 4.5:1 for normal text (AA), 7:1 for AAA, and 3:1 for large text. Check other pairs.
Color blindness simulation
How #0C0C31 looks to people with the most common types of color vision deficiency.
#001332Protanopia
no red cones#000f30Deuteranopia
no green cones#00151cTritanopia
no blue cones#111111Achromatopsia
no color vision
CSS examples
.background { background-color: #0c0c31; }
.text { color: #0c0c31; }
.border { border: 2px solid #0c0c31; }
.transparent { background-color: rgb(12 12 49 / 50%); }
.gradient { background: linear-gradient(to right, #0c0c31, #1f0c31); }
Similar colors
#071037Infinite Night#03012dMidnight#00022eIllicit Darkness#060929Mysterious Depths#000435Oblivion#1c0f33Midnight Monarch#111144Deadly Depths#041330Squid’s Ink
Closest common color name: Oxford Blue.
Questions
- What color is #0C0C31?
- #0C0C31 is a very dark, moderate blue, closest to the named color Infinite Night. It belongs to the black family of colors.
- What is the RGB value of #0C0C31?
- The RGB value is 12, 12, 49: 12 red, 12 green and 49 blue on a 0 to 255 scale.
- What is the complementary color of #0C0C31?
- The complementary color is #31310C, found by rotating the hue 180° on the color wheel.
- Is black or white text better on #0C0C31?
- White text. Black text has a contrast ratio of 1.11:1 and white text 18.88:1. WCAG asks for at least 4.5:1 for normal text.