Filter Pixels by Size Threshold
Remove specks: every connected group of pixels smaller than the size you set disappears. Runs entirely in your browser, so your data never leaves your device.
Runs on your device, nothing uploaded
Drop images anywhere on this page
or paste with Ctrl / ⌘ + V ·
Accepts PNG · several at once
Your PNG files never leave this tab
Filter Pixels by Size Threshold is JavaScript that your browser has already downloaded, and it does the whole job on your own machine. On a normal site, 200 photos straight off a camera means 1.6 GB uploaded, a wait in somebody's queue, and 240 MB downloaded again. Here it means 0 bytes up and 0 bytes down.
- No upload
- No file size limit
- Works offline once loaded
- Nothing stored or logged
How to use Filter Pixels by Size Threshold
- 1. Add the PNG. Drop in one or more PNG files with specks, dust or stray dots. Everything is processed in your browser.
- 2. Choose what forms a group. Pick non-transparent pixels for cut-outs, dark or light pixels for scans, or a picked color. Touching pixels, including diagonal neighbours, form one group.
- 3. Set the size limit and run. Every group smaller than the pixel count you set is removed. Opaque specks become transparent; colored, dark or light specks are filled from the pixels around them.
When to use Filter Pixels by Size Threshold
Filter Pixels by Size Threshold is a despeckle filter based on connected groups. It measures every group of touching pixels and removes the ones smaller than your limit, so isolated dots disappear while letters, lines and shapes above the size stay intact.
- Cleaning dust off a cut-out. A background removal often leaves tiny opaque islands around the subject. Removing groups smaller than a few pixels clears them in one pass.
- Despeckling a scanned page. Scans of paper pick up small dark specks. Targeting dark groups under about 20 pixels removes them while the text strokes, which are larger, stay sharp.
- Tidying a color mask. A mask painted in one color can have small stray blobs. Targeting that color with a size limit removes them and fills the gaps with the background.
Examples
Clean dust off a cut-out
Input
logo.png with stray opaque dots, smaller than 5 px
Output
logo.png with the dots made transparent
Despeckle a scan
Input
scan.png, dark pixels, smaller than 20 px
Output
scan.png with small dark specks filled from the paper around them
About the Filter Pixels by Size Threshold tool
Filter Pixels by Size Threshold does its work locally, right in the browser. Remove specks: every connected group of pixels smaller than the size you set disappears. There is no upload step, no queue and no account, and your data never travels over the network.
It belongs to the PNG Tools collection on EditSafely, a set of 292 small, focused PNG utilities that share the same instant, private workspace.
You can shape the output with 5 settings, including Pixels that form groups, Color, Color tolerance (%) and Brightness cut-off (%); the result is redone automatically when you change one. The finished file is put together in browser memory and saved with the Download button, so it never touches a server on the way to your disk. 2 worked examples further down the page show exactly what the tool produces for real inputs.
Running locally also makes the tool fast and dependable: the image is read straight from your device the moment you drop it, there is no server outage that can take it down mid-task, and private pictures stay private.
Frequently asked questions
Is Filter Pixels by Size Threshold free to use?
Yes, it is completely free. All 2,943 tools on EditSafely work without an account, a subscription or usage limits.
Are my files uploaded to a server?
Everything happens locally. Your browser downloads the tool's code once, then does all the processing itself; nothing you enter is transmitted, stored or logged. You can even go offline after the page loads and it will still work.
Which files does Filter Pixels by Size Threshold accept?
It accepts PNG images. There is no file size cap imposed by a server; very large files are limited only by your device's memory.
Do I need to sign up or install anything?
No. The tool works in any modern browser on desktop, tablet or phone. There is no account to create, no extension to add and no software to install.
How do I save the output?
Click the Download button once the result is ready. The file is built in your browser's memory and handed straight to your downloads folder, without passing through a server.
Related tools
All PNG Tools →Find Pixel Group Coordinates
Find every connected group of pixels and list its position, bounding box, size and centre.
Isolate Isolated Hot Pixels
Find single pixels far brighter or darker than all eight neighbours, then mark them or repair them with the neighbour median.
Delete Specific Target Pixels
Make the pixels of one color, or the pixels at the coordinates you list, fully transparent.
Shrink Selected Color Fields
Pull every area of a chosen color inward by a set number of pixels, filling the edge from its neighbours.