medium violet red color code
The hex code for medium violet red is #C71585, which is rgb(199, 21, 133) in RGB and cmyk(0%, 89%, 33%, 22%) in CMYK. It's a medium, rich magenta. It is a built-in CSS colour, so you can also write it as “mediumvioletred”.
Build a full palette from it: open in the palette generator.
Move the sliders to find a lighter, darker or softer medium violet red; the codes update as you go.
Medium Violet Red colour codes
| HEX | #C71585 |
|---|---|
| RGB | rgb(199, 21, 133) |
| HSL | hsl(322, 81%, 43%) |
| HSV / HSB | hsv(322, 89%, 78%) |
| CMYK | cmyk(0%, 89%, 33%, 22%) |
| Decimal | 13047173 |
| CSS keyword | mediumvioletred |
About medium violet red
Medium Violet Red sits at a hue of 322° on the colour wheel, with 81% saturation and 43% lightness. That makes it a colour that sits between warm and cool: greens and purples like this can be styled warm or cool depending on what you put next to them.
For text, white reads better on medium violet red. Medium Violet Red as text on a white background has a contrast ratio of 5.42:1, which passes the WCAG AA rule for body text (4.5:1). On black it is 3.87:1, which fails AA for body text.
Tints and shades of medium violet red
Tints mix medium violet red with white and shades mix it with black, in 10% steps. They're the easiest way to get lighter backgrounds and darker hover or text colours that still match.
Colours that go with medium violet red
Complementary — opposite on the colour wheel: maximum contrast
Analogous — neighbours 30° either side: calm and natural
Triadic — three hues 120° apart: lively but balanced
Split complementary — the two neighbours of the complement: contrast with less tension
Tetradic — four hues 90° apart: rich, use one as the main colour
Medium Violet Red text contrast
| Combination | Ratio | AA normal (4.5:1) | AA large (3:1) | AAA (7:1) |
|---|---|---|---|---|
| medium violet red on white | 5.42:1 | pass | pass | fail |
| medium violet red on black | 3.87:1 | fail | pass | fail |
Check medium violet red against any other colour in the contrast checker.
How medium violet red looks with colour blindness
Simulated with the Machado et al. (2009) model for the complete loss of one type of cone cell. Colour vision deficiency affects roughly 1 in 12 men and 1 in 200 women, most often as red-green colour blindness.
Use medium violet red in code
.medium-violet-red {
color: mediumvioletred;
background-color: #c71585;
border-color: rgb(199, 21, 133);
}Frequently asked questions
What is the hex code for medium violet red?
Medium Violet Red is #C71585 (lowercase #c71585). It's the official value of the CSS keyword “mediumvioletred”.
What is medium violet red in RGB, HSL and CMYK?
RGB: rgb(199, 21, 133). HSL: hsl(322, 81%, 43%). CMYK: cmyk(0%, 89%, 33%, 22%). CMYK is a simple conversion for reference; for professional printing, ask your printer for a matching ink or Pantone swatch.
What colours go with medium violet red?
Its complementary colour is #15C757 (close to emerald green), which gives the strongest contrast. For a calmer look, use the analogous colours #B015C7 and #C7152C, or the triadic pair #85C715 and #1585C7. Tints and shades of medium violet red itself always work together.
Is medium violet red a warm or cool colour?
Medium Violet Red has a hue of 322°, which makes it neither clearly warm nor cool.
Should I use black or white text on medium violet red?
White. Black text on medium violet red has a contrast ratio of 3.87:1 and white text has 5.42:1. WCAG asks for at least 4.5:1 for normal text and 3:1 for large text.
How do I use medium violet red in CSS?
Write color: mediumvioletred; or color: #c71585; — both give the same colour. Named colours work in every browser.