Inspect Indigo (#4B0082) in HEX, RGB, HSL, LCH and OKLCH, check its contrast, and copy the value you need.
Indigo
#4B0082
White text reads best on this background, at 12.95:1.
Indigo is one of the 148 CSS named colors, and resolves to #4B0082 in every browser. In numbers that is rgb(75, 0, 130) and hsl(275, 100%, 25%). Perceptually it is a dark, moderately saturated color: OKLCH puts its lightness at 34% and its chroma at 0.179. It sits in the purples at 302 degrees of OKLCH hue, and reads as a cool color.
White text clears WCAG AA on a Indigo background at 12.95:1, and AAA as well. That combination of lightness and chroma makes it a workable mid-tone, the kind of value that lands in the middle of a shade scale.
The closest CSS named colors to Indigo, measured with CIEDE2000, are DarkBlue (#00008B), Navy (#000080), MidnightBlue (#191970). If Indigo is not quite right, those are the nearest keywords to try before reaching for a custom value.
HEX
#4B0082
RGB
rgb(75, 0, 130)
HSL
hsl(275, 100%, 25%)
HWB
hwb(275 0% 49%)
CMYK
cmyk(42%, 100%, 0%, 49%)
LAB
lab(19.72 47.03 -54.28)
LCH
lch(19.72 71.82 310.91)
OKLCH
oklch(33.9% 0.1793 301.68)
WCAG asks for 4.5:1 between body text and its background. On #4B0082 white text measures 12.95:1 and black text 1.62:1, so white clears it and black does not.
White text on Indigo
WCAG 2.2
12.95:1
APCA
Lc 100
Passes AA body text
Passes AAA body text
Passes AA large text
Black text on Indigo
WCAG 2.2
1.62:1
APCA
Lc 0
Fails AA body text
Fails AAA body text
Fails AA large text
Check Indigo against any other color in the contrast checker.
Indigo sits at 34% OKLCH lightness. Holding its hue and chroma and moving only that value carries it up to #FAF7FF and down to #0A0019, which keeps the family recognizable instead of letting it drift toward gray the way a plain HSL ramp does.
#6E36AB
20% lighter
#935ED6
40% lighter
#BA88FF
60% lighter
#D8C1FF
80% lighter
#FAF7FF
100% lighter
#3D006B
20% darker
#2F0055
40% darker
#220040
60% darker
#16002C
80% darker
#0A0019
100% darker
Build a full accessible scale from #4B0082 in the shade generator.
Hues rotated around #4B0082 in OKLCH, then pulled back into the sRGB gamut. Each swatch is labelled with the nearest CSS named color so you have a keyword to start from.
Indigo sits at 302 degrees. Rotating it a half turn lands on 122 degrees, the hue directly opposite. It is the strongest pairing you can make without changing lightness, and the one most likely to vibrate if you use both at full chroma.
The neighbors of Indigo at 272 and 332 degrees. They stay close enough to read as the same family, which is what you want for hover states, secondary surfaces and gradients.
302, 62 and 182 degrees divide the wheel into thirds. Balanced enough to carry a whole palette without one color dominating the other two.
Instead of the complement at 122 degrees, this pair flanks it at 92 and 152. You keep most of the contrast of a complementary pairing while losing the harshness.
Explore more combinations around Indigo on the color wheel.
The biggest shift is under achromatopsia, where #4B0082 reads as #191919, 28.9 CIEDE2000 units away. If Indigo is the only thing marking a state or a series, roughly one viewer in twelve will miss it.
Protanopia
#001588
Deuteranopia
#001B7D
Tritanopia
#470D28
Achromatopsia
#191919
The nearest CSS keywords to #4B0082, ranked by perceptual distance rather than by how close their hex digits happen to look.