mask-size
Widely availableSince 202397% of users
Sets the size of the mask image. You can use keywords like 'cover' or 'contain', or specific pixel/percentage values, just like 'background-size'.
What's modern
From web-features, MDN's browser data and our snippets, checked dailyModernIn every major browser since December 2023. Widely available since June 2026.
See how modern your own CSS is.Check your CSS →
Quick facts
- Initial value
auto- Inherited
- No
- Applies to
- all elements and SVG container elements
- Animation type
- repeatableList
Quick example
.masked-element {
/* Scales the mask image to cover the entire element */
mask-size: cover;
}mask-size browser support
BaselineWidely availableThis feature is well established and works across many devices and browser versions. It has been available across browsers since 2023.Safe to use without fallbacks.
Usage97%of people can use this3% use a browser without it.
Browsers
120+
53+
15.4+
120+Mobile
120+Android
53+Android
15.4+iOS