Image Shape Masker
Crop into a circle, rounded rect, star, blob or custom SVG path with a true-alpha PNG export.
Mask settings
circle mask, feather 0px100×100 px at 0, 0. Drag-focused stage accepts arrow keys to move and +/- to scale.
Preview
no imageChoose an image to mask
Drop a file with the picker, then pick a shape and export a transparent PNG.
All decoding, masking and PNG encoding happen in this tab. Nothing is uploaded; the exported file keeps real alpha outside the mask.
Applies geometric masks — circle, rounded rectangle, star, blob and custom SVG path data — to an uploaded image and exports a flattened PNG whose masked-out area has real alpha zero. The mask can be positioned numerically, fitted with contain/cover/stretch, inverted, and feathered up to 40 px using a blurred alpha mask. Custom paths are token-validated with command-level error reporting, and JPEG/WebP exports warn about transparency flattening.
Examples
Team avatar
400×400 headshot, circle maskavatar.png with transparent cornersThe ellipse path is rasterized at source resolution, so the exported corners have alpha 0 rather than white pixels.
Badge sprite
5-point star, 50% inner radius, 8 px featherbadge.png with graded edgesThe blurred alpha layer gives the star soft edges while the interior remains fully opaque.
Hexagon from SVG
M 100 0 L 200 50 L 200 150 L 100 200 L 0 150 L 0 50 Zhexagonal masked PNGAny spec-compliant path data works; malformed commands are reported with a segment number instead of silently truncated.
About this tool
Image Shape Masker crops a photo into a geometric silhouette — circle, rounded rectangle, star, blob or a pasted SVG path — and exports a PNG whose outside area is genuinely transparent. Unlike CSS border-radius values, the shape is baked into the pixels, so the file is ready for avatars, badges, stickers and social cards anywhere.
The mask is an alpha layer: the image is composited with destination-in against a white shape, optionally blurred first for a feathered edge, or with destination-out when inverted to keep the outside instead. Numeric position and size inputs mirror the stage, contain/cover/stretch fit presets set the initial rectangle, and arrow keys or +/- nudge and scale a selected mask precisely.
Everything happens in the browser tab. Custom SVG path data is validated command by command — browsers otherwise truncate invalid paths silently — and errors report the offending segment. JPEG and WebP exports are available with a flatten color, with an explicit warning that those formats cannot store alpha.
What this tool does not do
- Geometry only: the tool does not segment subjects from backgrounds; use a background remover for content-aware cutouts.
- Canvas filter support varies by browser; where blur filters are unavailable the preview may show a harder edge and PNG export should be checked visually.
- Very large images are previewed at a reduced proxy size; export re-runs the same composite at source resolution and may take longer on high-megapixel files.
How to use this tool
Choose an image
Pick a PNG, JPEG or WebP file. The source is decoded locally and shown over a checkerboard that makes transparency obvious.
Pick a mask
Choose circle, rounded rectangle, star, blob or custom. Adjust radius, points, inner radius or paste SVG path data.
Position and soften
Set x/y/size numerically or use the fit preset and keyboard stage; add feather up to half the smaller mask side and invert if needed.
Export
Download PNG for real alpha, or choose JPEG/WebP and select a flatten color after reading the transparency warning.
Use cases
Avatars and profile art
Cut headshots or logos into circles without leaving a white halo in apps that expect transparent PNGs.
Game and UI badges
Create star or blob-shaped sprites with a controllable soft edge for overlays and achievements.
Social preview images
Round the corners of an Open Graph image and export a ready-to-upload asset instead of a CSS value.
Mask behavior at a glance
| Setting | Values |
|---|---|
| Shape | circle / rounded-rect / star / blob / custom |
| Fit | contain / cover / stretch |
| Feather | 0–40 px |
| Invert | on / off |
| Export | PNG / JPEG / WebP |
Feather is capped at half the smaller mask dimension minus one pixel so the shape cannot disappear entirely.
Common mistakes
Mistake:Exporting as JPEG and expecting transparent corners.
Fix:JPEG has no alpha channel. Use PNG, or deliberately choose a flatten color when exporting JPEG/WebP.
Mistake:Pasting a full <svg> element into the custom path field.
Fix:The field takes only the d attribute value — the M/L/C/A/Z commands and their numbers.
Mistake:Using a feather larger than half the mask.
Fix:The tool caps feathering at min(width, height)/2 − 1 so the alpha shape cannot vanish.
Frequently asked questions
Is the exported PNG really transparent at the corners?
Yes. The image is composited against a white alpha mask with destination-in (or destination-out when inverted), and the result is encoded as PNG. Pixels outside the shape have alpha 0 — they are not white pixels that merely look transparent. The checkerboard preview shows the same alpha the file will contain.
How do I make soft or feathered edges?
Move the Feather slider anywhere from 0 to 40 pixels. The mask is blurred before compositing, so its alpha ramps from opaque to transparent across the edge. The value is capped at half the smaller mask dimension minus one pixel to prevent the shape from disappearing; preview and export scale the blur to their respective resolutions so the edge looks the same in both.
Can I use my own SVG shape?
Yes. Select Custom SVG path and paste the value of a path element's d attribute — commands like M, L, C, A and Z with their numeric arguments. A full <svg> wrapper is not accepted. The data is tokenized command by command, so an error reports the 1-based segment number and the expected argument count instead of the browser silently truncating the path.
Why does JPEG export flatten my transparency?
JPEG and WebP (in its common opaque form) cannot store an alpha channel, so the area outside the mask must be filled with something. When you select either format, the tool shows a flatten-color picker and a warning. Choose PNG whenever the transparent background is the point of the asset.
Can the mask keep its aspect ratio?
The initial rectangle uses contain, cover or stretch: contain fits the whole mask inside the image, cover fills the image and may extend past its edges, and stretch uses the full image rectangle. After that you can change width and height independently. Keyboard +/- scales around the mask center, and arrow keys move it by one pixel.
Does the tool upload or store my images?
No. Decoding, masking and encoding all happen in this browser tab, and the downloaded file is generated locally. There is no network request, account, watermark or localStorage payload for image data — closing the tab discards everything.
References & standards
Related tools
APCA Contrast Calculator
Calculate directional APCA 0.1.9 Lc contrast scores and compare them with WCAG 2.1 ratios.
Barcode Generator
Generate barcodes in 8 formats (CODE128, EAN13, UPC, and more) — configure line width, height, and text display, then download as SVG or PNG.
Base64 Image Encoder
Open the Image workspace in Base64 Toolbox to resize and convert images to Base64 data URIs, then copy HTML, CSS, Markdown or JavaScript snippets.
Batch Image Resizer
Resize multiple images with width, height, percentage or max-dimension rules and renaming, privately.
BlurHash Generator
Encode an image into a compact BlurHash string and verify it with a live decode preview.
CSS Container Queries Lab
Generate CSS container queries and preview responsive component patterns