clip-path
Widely availableSince 202097% of users
Creates a clipping region that sets what part of an element should be shown. Parts inside the region are visible, while those outside are hidden.
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.
The old way and the modern waySee the snippet: Responsive clip paths without SVG →
Old way 3 lines
.shape {
clip-path: path('M0 200 L100 0 L200 200 Z');
}Modern 7 lines
.shape {
clip-path: shape(
from 0% 100%,
line to 50% 0%,
line to 100% 100%
);
}Newer parts of clip-path
fill-boxBaseline Nov 2023, Widely May 2026stroke-boxBaseline Nov 2023, Widely May 2026view-boxBaseline Nov 2023, Widely May 2026path()Baseline Jan 2021, Widely Jul 2023
See how modern your own CSS is.Check your CSS →
Quick facts
- Initial value
none- Inherited
- No
- Applies to
- all elements and SVG container elements
- Animation type
- basicShapeOtherwiseNo
Quick example
.hero-shape {
clip-path: polygon(0% 0%, 100% 0%, 100% 75%, 50% 100%, 0% 75%);
/* creates a pointed banner/hero shape */
}Values
noneRelated snippet
Responsive clip paths without SVGAnimation →clip-path 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
55+
3.5+
9.1+
79+Mobile
55+Android
4+Android
9.3+iOS