What Is CSS clip-path?
clip-path is a CSS property that clips an element to a defined shape, masking everything outside it. It is supported in all modern browsers and works on any HTML element — <div>, <img>, <video>, and SVG elements.
Supported Shape Functions
| Function | Syntax | Use Case |
|---|---|---|
polygon() | polygon(x1% y1%, x2% y2%, …) | Any custom multi-point shape |
circle() | circle(r% at cx% cy%) | Circular crop |
ellipse() | ellipse(rx% ry% at cx% cy%) | Oval / stretched circle |
inset() | inset(top% right% bottom% left% round r%) | Rectangular crop with rounded corners |
How to Use
- Choose a shape type — Polygon, Circle, Ellipse, or Inset using the tabs
- Drag handles — in Polygon mode, drag the blue circles on the preview to reposition points
- Add or remove points — click + Point to add a new polygon vertex, or Remove to delete the selected one
- Apply a preset — choose from Triangle, Rhombus, Hexagon, Arrow, Star, Circle, or Ellipse
- Adjust sliders — for Circle, Ellipse and Inset, use the sliders to fine-tune radius and position
- Copy CSS — click Copy to copy the
clip-pathdeclaration to your clipboard
Polygon Coordinates
All values are percentages relative to the element’s bounding box:
0% 0%= top-left corner100% 0%= top-right corner50% 100%= bottom center100% 50%= right center
This means the shape scales automatically with any element size.
Preset Shapes
| Preset | Points | Description |
|---|---|---|
| Dreieck | 3 | Equilateral triangle pointing up |
| Rhombus | 4 | Diamond / rotated square |
| Hexagon | 6 | Regular flat-top hexagon |
| Pfeil | 7 | Left-pointing arrow |
| Stern | 10 | 5-pointed star |
Browser Support
clip-path with shape functions is supported in Chrome 55+, Firefox 54+, Safari 9.1+, and Edge 12+. No vendor prefixes are needed in modern browsers.
Privacy
All clip-path generation and preview rendering happens locally in your browser. No shape data or CSS code is ever sent to a server.