Skip to content
Toolars
Explore
Report bug

Design · Local utility

CSS Clip Path Generator

Edit polygon points by dragging, keyboard or coordinates. Start with four presets and copy a clip-path declaration or full CSS, locally.

Task path / input to outcome

Choose a starting shape

Runs locally · Nothing is uploaded

CSS clip-path examples you can reproduce

Compare four polygon shapes, then match the settings in the workspace. Each preview uses the same polygon as its CSS; the exported starting box is 240 × 180 px.

Adjust these settings in the workspace

Hexagon

Use a hexagon for a team avatar or a repeated badge.

Horizontal point
24%
Vertical point
50%
Shape color
#0f4cff
View CSS
.clipped-shape {
  width: 240px;
  aspect-ratio: 4 / 3;
  background: #0f4cff;
  -webkit-clip-path: polygon(24% 0%, 76% 0%, 100% 50%, 76% 100%, 24% 100%, 0% 50%);
  clip-path: polygon(24% 0%, 76% 0%, 100% 50%, 76% 100%, 24% 100%, 0% 50%);
}

Diamond

Try an angled diamond for a small image or decorative accent.

Horizontal point
35%
Vertical point
50%
Shape color
#0f4cff
View CSS
.clipped-shape {
  width: 240px;
  aspect-ratio: 4 / 3;
  background: #0f4cff;
  -webkit-clip-path: polygon(65% 0%, 100% 50%, 35% 100%, 0% 50%);
  clip-path: polygon(65% 0%, 100% 50%, 35% 100%, 0% 50%);
}

Parallelogram

Use a slanted four-point shape for a card accent.

Horizontal point
18%
Vertical point
40%
Shape color
#0f4cff
View CSS
.clipped-shape {
  width: 240px;
  aspect-ratio: 4 / 3;
  background: #0f4cff;
  -webkit-clip-path: polygon(18% 0%, 100% 60%, 82% 100%, 0% 40%);
  clip-path: polygon(18% 0%, 100% 60%, 82% 100%, 0% 40%);
}

Chevron

Point a banner edge toward the next section.

Horizontal point
18%
Vertical point
50%
Shape color
#0f4cff
View CSS
.clipped-shape {
  width: 240px;
  aspect-ratio: 4 / 3;
  background: #0f4cff;
  -webkit-clip-path: polygon(0% 0%, 82% 0%, 100% 50%, 82% 100%, 0% 100%, 18% 50%);
  clip-path: polygon(0% 0%, 82% 0%, 100% 50%, 82% 100%, 0% 100%, 18% 50%);
}

Apply a shape to an image

Start with the CSS from any shape above, then add these rules after it. Replace the image path and alt text with your own. The box keeps a 4:3 ratio; object-fit: cover crops the image to fill it without stretching. Percentage coordinates follow the box when it resizes.

<img class="clipped-shape"
  src="/your-image.jpg"
  alt="Describe your image"
  width="240" height="180">
.clipped-shape {
  display: block;
  max-width: 100%;
  height: auto;
  object-fit: cover;
}

Four templates and two sliders are available. Free vertex editing, SVG path imports and curves are not supported. To copy or download a customized rule, use Copy CSS or Download .css in the workspace.

How CSS Clip Path Generator works, privacy, and related tools

Task path / input to outcome

How to build a CSS clip-path polygon

  1. 01

    Choose a starting shape

    Choose Hexagon, Diamond, Parallelogram or Chevron. The two sliders adjust the preset; editing an individual point switches to a custom polygon.

  2. 02

    Edit the vertices

    Drag a numbered point or use the coordinate fields. Arrow keys move a focused point by 1%; Shift + arrow moves it by 10%. Add inserts a midpoint after the selected point.

  3. 03

    Set the preview color

    The full example uses your color, a 240px width and a 4:3 aspect ratio. The editor scales to fit the screen.

  4. 04

    Check the silhouette

    Review all edges before exporting. Numbered handles are editing controls and are not part of the CSS.

  5. 05

    Choose an output format

    CSS output: Clip-path declaration only / Full example CSS. The full example uses your color, a 240px width and a 4:3 aspect ratio. The editor scales to fit the screen.

  6. 06

    Apply and check in your layout

    Percentage coordinates scale with the element. Paste the declaration into an existing rule, or apply the .clipped-shape class from the full example. Check the result at desktop and mobile sizes.

Tool facts

Processing
In your browser
Input leaves this device
Never
Retention
Nothing is stored
Price
Free

Your input stays in the browser.

CSS Clip Path Generator uses its verified local execution path and does not create a hidden input or output history.

Local execution

Runs inside the current browser tab.

No hidden processing

Active tool data never becomes a Toolars document record.

No account required

Use the core workflow without creating a profile. Favorites sync to your account after you sign in.

Immediate reset

Clear the tab and the active working data is gone.

When CSS Clip Path Generator is useful

Shape a six-point orange cutout

In a 2026-09-24 local browser run, start from the default Hexagon (horizontal 24%, vertical 50%). Select point 1, change X from 24% to 30%, and set the color to #ff6600. The preview becomes an orange six-point polygon with clip-path polygon(30% 0%, 76% 0%, 100% 50%, 76% 100%, 24% 100%, 0% 50%); the other five points stay in their original order.

Copy the rule that matches the preview

Full example CSS uses .clipped-shape with width 240px, aspect-ratio 4 / 3, background #ff6600 and both -webkit-clip-path and clip-path. Copy CSS matched the downloaded toolars-clip-path.css (240 bytes). Switching CSS output to Clip-path declaration only and copying gave exactly clip-path: polygon(30% 0%, 76% 0%, 100% 50%, 76% 100%, 24% 100%, 0% 50%); (73 UTF-8 bytes). Apply it to an element in your own layout to check the crop.

Recover from an out-of-range point

Set point 1 X to 101%. The 2026-09-24 workspace reported that points must be finite and between 0 and 100%; the orange preview and generated CSS cleared, and Copy CSS and Download .css became disabled. Set X back to 30% to restore polygon(30% 0%, 76% 0%, 100% 50%, 76% 100%, 24% 100%, 0% 50%), then copy again. Crossing edges are not repaired automatically.

What CSS Clip Path Generator actually does

Start with four presets, then add, delete or move polygon points. Export a clip-path declaration or full example CSS. Percentage coordinates scale with the element. Paste the declaration into an existing rule, or apply the .clipped-shape class from the full example. Check the result at desktop and mobile sizes.

Common questions

What do the two output formats contain?
Clip-path declaration only: clip-path: polygon(…). Full example CSS: .clipped-shape — width, aspect-ratio, background, -webkit-clip-path, clip-path. The full example uses your color, a 240px width and a 4:3 aspect ratio. The editor scales to fit the screen.
How do I restore a preset?
Choose one of the four presets to replace custom vertices. Reset restores the default hexagon, color and full CSS output; Load sample opens the Chevron example.
What shapes and limits are supported?
Edit polygon() with 3–32 vertices and X/Y coordinates from 0 to 100%. Circles, ellipses, inset shapes, SVG paths, CSS import and animation are not included.
Can I preview an uploaded image?
The editor previews a flat color. Apply the exported CSS to your own image or background in your project to check the crop.
Does editing upload or save my data?
Coordinates and CSS stay in this tab. There is no workspace storage or content telemetry. Copy or download before leaving.
What happens with invalid coordinates?
For example, X = 101% is outside the 0–100% range: the shape and CSS clear and export is disabled. Change X to 50% to recover, then inspect the polygon before copying. Reset also restores the default shape.
Can edges cross?
Yes. Vertices are connected in list order and CSS uses the default nonzero fill rule. Crossings, repeated points or a collapsed shape are not automatically repaired.

Keep reading

Continue in Design

Related tasks, not a dead end.

Move into another focused workspace without returning to the full index.

CSS Loader Generator

Design an orbit-ring or three-dots loading spinner with size, stroke, speed, and color controls, and copy CSS that respects reduced motion.

Create

CSS Checkbox Generator

Style a custom checkbox with size, border, and state colors, and copy CSS that keeps a real, keyboard-accessible input underneath.

Create

CSS Switch Generator

Design a pure-CSS toggle switch with track, thumb, and two-state colors, and copy code with focus and reduced-motion handling included.

Create

CSS Background Pattern Generator

Compose dots, grid, or diagonal background patterns from pure CSS gradients — no image file — with tile, mark, and color controls.

Create