vector-effect
Widely availableSince 202097% of users
Specifies a vector effect to be applied to an SVG shape. The most common value is 'non-scaling-stroke', which ensures that lines stay at the same thickness even when you scale up the entire SVG image.
What's modern
From web-features, MDN's browser data and our snippets, checked dailyModernIn every major browser since January 2020. Widely available since July 2022.
See how modern your own CSS is.Check your CSS →
Quick facts
- Initial value
none- Inherited
- No
- Applies to
- SVG graphics elements and <use>
- Animation type
- discrete
Quick example
.icon-path {
stroke-width: 2px;
/* keeps the stroke width at exactly 2px regardless of how much we zoom or scale the SVG */
vector-effect: non-scaling-stroke;
}Values
nonenon-scaling-strokenon-scaling-sizenon-rotationfixed-positionvector-effect browser support
BaselineWidely availableThis feature is well established and works across many devices and browser versions. It has been available across browsers since 2020.Safe to use without fallbacks.
Usage97%of people can use this3% use a browser without it.
Browsers
6+
15+
5.1+
79+Mobile
18+Android
15+Android
5+iOS