#0C052D

A color in the Violet family

#0c052d is a color in the Violet family: RGB(12, 5, 45), HSL(251°, 80%, 10%), CMYK(73%, 89%, 0%, 82%). Closest named color: midnightblue. Contrast is 19.53:1 on white and 1.08:1 on black. See shades, harmonies and color-blindness simulation.

Color Codes

HEX#0c052d
RGBrgb(12 5 45)
RGB (legacy)rgb(12, 5, 45)
RGB %rgb(5% 2% 18%)
HSLhsl(251 80% 10%)
HSV / HSBhsv(251, 89%, 18%)
HWBhwb(251 2% 82%)
CMYKcmyk(73%, 89%, 0%, 82%)
CIELAB (D50)lab(3.16 10.38 -23.81)
LCHlch(3.16 25.97 293.56)
OKLaboklab(0.1637 0.0171 -0.0746)
OKLCHoklch(0.1637 0.0765 282.89)
Decimal787757

Properties

Color ToneViolet
Closest named colormidnightblue ΔE 14.3
Closest web-safe color#000033
Hue251°
Saturation (HSL / HSV)80% / 89%
Lightness (HSL)10%
Brightness or Value (HSV)18%
Luminance (Rec.601 / Rec.709)5% / 4%
Relative luminance (WCAG)0.0038
Red / Green / Blue12 / 5 / 45

WCAG 2.2 Contrast Ratio

On White (#ffffff)
19.53:1
AA Normal (4.5:1) · PassAA Large (3:1) · PassAAA Normal (7:1) · Pass
On Black (#000000)
1.08:1
AA Normal (4.5:1) · FailAA Large (3:1) · FailAAA Normal (7:1) · Fail
Aa Bb 123

APCA Contrast Lc (reference) — As text on white / black: Lc 105.4 / 0 · As background with white / black text: Lc -107.4 / 0

Lightness Scale (OKLCH 50–950)

Eleven steps that change only perceived lightness while keeping hue and chroma — ready to use as design-system color tokens.

Tints (mixed with white)

Shades (mixed with black)

Color Harmonies

Color Vision Deficiency Simulation

Estimated appearance of this color for people with color vision deficiencies (Machado 2009).

Similar Named Colors

Use in CSS

:root {
  --color-brand: #0c052d;
  --color-brand-oklch: oklch(16.37% 0.0765 282.89);
}
.text { color: var(--color-brand); }
.background { background-color: var(--color-brand); }
.border { border: 1px solid rgb(12 5 45 / 50%); }
/* Tailwind CSS */
<div class="bg-[#0c052d] text-[#0c052d] border-[#0c052d]">