PUBLIC.INTERNET

CSS Clip-Path Generator

Choose from seven ready-made clip-path: polygon() shapes and see the mask applied to a 256 px square, filled with a solid color or an image you upload. The CSS box shows both the -webkit-clip-path and standard clip-path declarations so you can copy them straight into a rule. It is a preset picker, not a point-by-point editor.

Live Preview

Shape

Upload an image or use a solid color to see how the clip-path mask works

CSS Code


      
    

How to get a clip-path

  1. Open Shape Preset and pick Triangle, Pentagon, Hexagon, Arrow Right, Chevron, Star, Message Bubble, or Custom Points.
  2. Change Background Color to recolor the shape, or use Upload Image (Optional) to fill it with a photo, scaled with cover. Once an image is loaded the color no longer shows.
  3. Check the Live Preview, then read the declarations under CSS Code.
  4. Click Copy CSS to copy both lines.

How polygon() percentages behave

Every point in polygon() is an x and y pair measured from the top-left of the element's reference box, so 50% 0% is the top center and 100% 100% is the bottom right. Percentages scale with the element, which is why the same shape stays proportional when you move it from a 256 px square to a full-width banner.

Anything outside the polygon is clipped for painting and for hit testing, so clicks on the cut-away corners do not register on the element. Clipping also cuts off box-shadows and borders that extend past the shape, so a drop shadow needs a wrapper element or filter: drop-shadow() on a parent. The preview shape is fixed at a square, so shapes designed for other aspect ratios, such as the speech bubble's tail, may look different on your real element. The Custom Points option here is only a diamond, not a free-form editor.