Maroon Colors  ·  Color Library

Palettes / Colors / #28126D

#28126D — Deep Purple

#28126D is a purple color we call Deep Purple, closest to the named color MidnightBlue (#191970). It belongs to the purple family.

Color name

Closest CSS keyword: midnightblue (#191970) — not an exact match. CSS midnightblue gives you #191970, a different color; use #28126D when you need this exact shade.

Sources: common names follow widely used color-name references; CSS keywords and their hex values follow the CSS Color specification.

#28126D is a cool purple color associated with luxury, creativity and mystery. It is saturated enough to be the accent — buttons, highlights and calls to action — while neutrals do the quiet work around it.

Its strongest partner is its complement #576E12; it also sits naturally between #12296E and #57126E. In the palettes below you can see it working alongside real color combinations from our collection.

#28126D · RGB 40, 18, 109

Download PNG swatch SVG

Color values

HEX#28126D
RGB40, 18, 109
HSL255°, 72%, 25%
HSV255°, 83%, 43%
CMYK63%, 83%, 0%, 57%
XYZ3.85, 1.99, 14.65
Yxy1.99, 0.1880, 0.0970
CIE-Lab15.42, 36.30, -48.30
Hunter Lab14.10, 25.24, -54.52

RGB & CMYK percentages

Red 16% · Green 7% · Blue 43%

Cyan 63% · Magenta 83% · Yellow 0% · Key 57%

CMYK values are unprofiled approximations for screen reference — not a print-proofing guarantee.

Previews

Sample text in #28126D on black
Lorem ipsum dolor sit amet, consectetur adipiscing elit.
Sample text in #28126D on white
Lorem ipsum dolor sit amet, consectetur adipiscing elit.

CSS code for #28126D

.text { color: #28126D; }
.background { background-color: #28126D; }
.border { border: 3px solid #28126D; }
.text-rgb { color: rgb(40, 18, 109); }
.text-hsl { color: hsl(255, 72%, 25%); }
.text-shadow-hex { text-shadow: 4px 4px 2px #28126D; }
.text-shadow-rgba { text-shadow: 4px 4px 2px rgba(40, 18, 109, 0.8); }
.box-shadow-hex { box-shadow: 1px 1px 3px 2px #28126D; }
.box-shadow-rgba { box-shadow: 1px 1px 3px 2px rgba(40, 18, 109, 0.8); }

HTML: <p style="color:#28126D">Text here</p> · <div style="background-color:#28126D">Div content here</div>

Shades of #28126D

#261065#220F5C#1F0E53#1C0C4B#180B42#140935#10072C#0D0623#0A041A#070312

Tints of #28126D

#34178C#401CAB#4B21CA#5C31DD#7854E3#9073E8#A891ED#C1B0F2#D9CFF7#F1EDFC

Tones of #28126D

#2C1867#2F1F60#33265A#362C54#39324D#3D3946

Color harmonies

Complementary — #576E12:

Analogous:

Triadic:

Contrast & accessibility

Against white text15.03:1 AAA
Against black text1.40:1 Fails

Best text color on #28126D: #FFFFFF.

Semi-transparent (opacity) text on #28126D

Text set with opacity blends into the background, so its real contrast is lower than the solid ratios above. Choose a text color and an opacity to see the blended color and its true ratio:

100%
Sample heading text
Smaller body text shows the effect best.

Blended color: · Contrast against #28126D: ·

How #28126D looks with color blindness

Simulated with standard Machado color-vision-deficiency matrices — useful when this color carries meaning in charts, maps or interfaces:

Protanopia · #1E1E57Deuteranopia · #202152Tritanopia · #274642

Closest design-system colors

The nearest matches in the Tailwind CSS, Material Design and Bootstrap palettes — handy when you need a framework class instead of a raw hex:

Bootstrap dark · #212529Tailwind slate 600 · #475569Tailwind gray 600 · #4B5563

Palettes with a similar color

These palettes use a close neighbour of #28126D rather than the exact color:

Royal Ruby Solace
#2A7EB1 · #1B38AB · #29176D · #471067
Honey Ruby Summit
#B9AFE9 · #8977DF · #5840C9 · #26186D
Dreamy Ruby Mirage
#1E537B · #2C176C · #7D2576 · #2B0A0E
Palette 211572
#211572 · #24BDDF · #F4F4F4 · #FFFDBB
Vintage Cascade
#251161 · #5A116D · #6D154F · #E1253B
Palette 211c6a
#211C6A · #59B4C3 · #74E291 · #EFF396

Similar colors

The closest colors that actually appear in our palette collection — click any to open its page:

#29176D#26186D#2C176C#211572#251161#211C6A#33186B#320A6B#22177A#282066#1C0770#1C1678

Browse neighbouring colors

← #28126C  ·  #28126E →

Frequently asked questions

What color is #28126D?

#28126D is Deep Purple, a purple color (RGB 40, 18, 109). Its closest standard named color is MidnightBlue.

What is the RGB and HSL of #28126D?

#28126D is RGB 40, 18, 109 — HSL 255°, 72%, 25% — CMYK 63%, 83%, 0%, 57%.

What colors go with #28126D?

Its complement is #576E12; analogous partners are #12296E and #57126E. It also appears in 6+ palettes in our collection.

Can I use #28126D for text?

White text on #28126D has a contrast ratio of 15.03:1 (passes WCAG AA); black text gives 1.40:1.