CSS named colour
Medium Violet Red
#c71585
A CSS named colour: mediumvioletred is valid anywhere a colour is expected.
- RGB
- rgb(199 21 133)
- HSL
- 322°, 81%, 43%
- OKLCh
- 55.3% 0.222 349.7
Medium Violet Red in every format
Web & CSSThe everyday formats for stylesheets and design tools.
| Hex | #c71585 | |
|---|---|---|
| RGB | rgb(199 21 133) | |
| RGB legacy | rgb(199, 21, 133) | |
| RGB percent | rgb(78.04% 8.24% 52.16%) | |
| HSL | hsl(322.2 80.9% 43.1%) | |
| HSL legacy | hsl(322.2, 80.9%, 43.1%) | |
| HSV / HSB | hsv(322.2, 89.4%, 78%) | |
| HWB | hwb(322.2 8.2% 22%) | |
| Nearest name | mediumvioletred | |
| CMYK | cmyk(0%, 89.4%, 33.2%, 22%)Naive conversion. Real print work needs an ICC profile. |
Perceptual & wide gamutModern CSS colour spaces for uniform scales and P3 displays.
| OKLCh | oklch(55.337% 0.22165 349.687)Modern CSS colour space for even palettes — better than HSL when building scales. | |
|---|---|---|
| OKLab | oklab(55.337% 0.21807 -0.03968) | |
| CIE LCh | lch(45.174% 70.973 348.569) | |
| CIE Lab | lab(45.174% 69.566 -14.066) | |
| Display P3 | color(display-p3 0.716 0.1763 0.5105) | |
| Rec. 2020 | color(rec2020 0.6043 0.1837 0.457) | |
| srgb-linear | color(srgb-linear 0.5711 0.0075 0.2346)Light-linear sRGB — the same numbers a shader wants for maths. | |
| CIE XYZ (D65) | color(xyz-d65 0.2805 0.1437 0.2349) |
ShadersGLSL, HLSL and WGSL vectors in both encoded and linear form.
| GLSL vec3 — sRGB | vec3(0.78, 0.082, 0.522)Encoded values. Use when writing straight to the framebuffer. | |
|---|---|---|
| GLSL vec3 — linear | vec3(0.571, 0.007, 0.235)Light-linear values. Use for lighting, blending and mixing. | |
| GLSL vec4 — sRGB | vec4(0.78, 0.082, 0.522, 1.0) | |
| GLSL vec4 — linear | vec4(0.571, 0.007, 0.235, 1.0) | |
| GLSL ivec3 | ivec3(199, 21, 133) | |
| HLSL float3 — sRGB | float3(0.78, 0.082, 0.522) | |
| HLSL float3 — linear | float3(0.571, 0.007, 0.235) | |
| HLSL float4 — sRGB | float4(0.78, 0.082, 0.522, 1.0) | |
| HLSL half4 — sRGB | half4(0.78, 0.082, 0.522, 1.0) | |
| WGSL vec3f — sRGB | vec3f(0.78, 0.082, 0.522) | |
| WGSL vec4f — sRGB | vec4f(0.78, 0.082, 0.522, 1.0) | |
| WGSL vec3<f32> — linear | vec3<f32>(0.571, 0.007, 0.235) |
Engines & appsConstructors for Unity, Unreal, Godot, Flutter, SwiftUI and Android.
| Unity Color | new Color(0.78f, 0.082f, 0.522f, 1.0f)Color for everyday scripting (0–1). Color32 when you need whole numbers from 0 to 255. | |
|---|---|---|
| Unity Color32 | new Color32(199, 21, 133, 255) | |
| Unreal FLinearColor | FLinearColor(0.5711f, 0.0075f, 0.2346f, 1.0f)FLinearColor for materials and lighting. FColor when you need whole numbers from 0 to 255. | |
| Unreal FColor | FColor(199, 21, 133, 255)Whole numbers from 0 to 255 — use when an API asks for FColor, not FLinearColor. | |
| Godot Color | Color(0.78, 0.082, 0.522, 1) | |
| Flutter Color | Color(0xFFC71585)Packed ARGB, so alpha comes first. | |
| Android Color | Color.rgb(199, 21, 133) | |
| SwiftUI Color | Color(red: 0.78, green: 0.082, blue: 0.522) | |
| UIKit UIColor | UIColor(red: 0.78, green: 0.082, blue: 0.522, alpha: 1) |
Raw valuesPacked integers and plain arrays.
| 0x hex | 0xC71585 | |
|---|---|---|
| 0x hex (ARGB) | 0xFFC71585 | |
| Array 0–1 | [0.78, 0.082, 0.522] | |
| Array 0–255 | [199, 21, 133] | |
| Decimal integer | 13047173 |
Contrast and accessibility
WCAG 2 ratios are what audits and legislation reference. APCA is shown alongside because WCAG 2 is known to misjudge mid-tone backgrounds, and it is the basis of the WCAG 3 draft.
| Pairing | WCAG 2 ratio | Level | APCA | Suitable for |
|---|---|---|---|---|
| Medium Violet Red on white | 5.42:1 | AA | Lc 75 | Body text, 18px and up |
| Medium Violet Red on black | 3.87:1 | AA Large | Lc 27 | Not usable for text |
Medium Violet Red text on a white background
Medium Violet Red text on a black background
White text on Medium Violet Red
Black text on Medium Violet Red
Tonal scale
Hue held fixed while lightness walks OKLCh, ready to use as a design system ramp.
- 50#ffedfb
- 100#ffdef3
- 200#ffc4e5
- 300#ff9dd3
- 400#ff64bd
- 500#e53d9f
- 600#c41c83
- 700#a4006b
- 800#870056
- 900#6d0044
- 950#430027
Tints and shades
Mixed perceptually toward white and black, so the steps feel evenly spaced.
- Tint 1#d54f99
- Tint 2#e175ac
- Tint 3#ec99c1
- Tint 4#f4bbd5
- Tint 5#fbddea
- Shade 1#9c0e67
- Shade 2#72074b
- Shade 3#4c0330
- Shade 4#280117
- Shade 5#090004
Colours that work with Medium Violet Red
Complementary, triadic and analogous partners, rotated in OKLCh so they keep the same apparent brightness.
- #008a66
- #797800
- #007fb0
- #a733c1
- #d50138
Closest CSS names
mediumvioletredexact matchdeeppinkΔEok 0.113crimsonΔEok 0.118darkmagentaΔEok 0.134mediumorchidΔEok 0.134indianredΔEok 0.141