#402D62 color
The hex color #402D62 is a dark, desaturated violet.
In the RGB color model it is made of 25.1% red, 17.6% green and 38.4% blue (64, 45, 98).
Its hue angle is 262°, with 37% saturation and 28% lightness. For print, the CMYK equivalent is 35% cyan, 54% magenta, 0% yellow and 62% black.
The closest named color is Her Highness (#432E6F), a difference of 2.9 ΔE, a small difference.
White text is the more readable choice on this background (contrast 11.87:1).
#402D62 color codes
| HEX | #402D62 | |
|---|---|---|
| RGB | rgb(64, 45, 98) | |
| RGB percent | rgb(25.1%, 17.6%, 38.4%) | |
| HSL | hsl(262, 37%, 28%) | |
| HSV / HSB | hsv(262, 54%, 38%) | |
| CMYK | cmyk(35%, 54%, 0%, 62%) | |
| CIE LAB | lab(23.16, 21.69, -28.41) | |
| CIE LCH | lch(23.16, 35.75, 307.36) | |
| CIE XYZ | xyz(5.257, 3.849, 12.019) | |
| Decimal | 4205922 | |
| Short hex | None (no 3-digit form) |
Color harmonies
Colors that go with #402D62, 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 #402D62 | Ratio | AA | AAA | AA large |
|---|---|---|---|---|
| Sample text | 1.77:1 | Fail | Fail | Fail |
| Sample text | 11.87:1 | Pass | Pass | Pass |
| #402D62 as text on | Ratio | AA | AAA | AA large |
|---|---|---|---|---|
| Sample text | 11.87:1 | Pass | Pass | Pass |
| Sample text | 1.77: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 #402D62 looks to people with the most common types of color vision deficiency.
#1a3764Protanopia
no red cones#1f3761Deuteranopia
no green cones#393743Tritanopia
no blue cones#373737Achromatopsia
no color vision
CSS examples
.background { background-color: #402d62; }
.text { color: #402d62; }
.border { border: 2px solid #402d62; }
.transparent { background-color: rgb(64 45 98 / 50%); }
.gradient { background: linear-gradient(to right, #402d62, #5b2d62); }
Similar colors
#432e6fHer Highness#372354Stormy Night#48295bAcai#322c56Purple Noir#442266Fading Horizon#4a3b6aMeteorite#4b2c74Mystic Nights#372d52Midnight Pie
Closest common color name: Dark Slate Blue.
Questions
- What color is #402D62?
- #402D62 is a dark, desaturated violet, closest to the named color Her Highness. It belongs to the purple family of colors.
- What is the RGB value of #402D62?
- The RGB value is 64, 45, 98: 64 red, 45 green and 98 blue on a 0 to 255 scale.
- What is the complementary color of #402D62?
- The complementary color is #4F622D, found by rotating the hue 180° on the color wheel.
- Is black or white text better on #402D62?
- White text. Black text has a contrast ratio of 1.77:1 and white text 11.87:1. WCAG asks for at least 4.5:1 for normal text.