Free up storage
How to Find Old Zip Archives Eating Storage on Your Mac
Find every zip, tar, and rar archive on your Mac with Smart Folders, mdfind, and Terminal. Reclaim space from extracted-then-forgotten downloads.
You download a zip, double-click it, macOS extracts it, you use the contents, and the original zip stays in Downloads forever. Multiply that by every project, software download, and email attachment over a few years and you can easily have 30GB+ of redundant archive files sitting around.
Old archives are some of the easiest deletion candidates on a Mac. By definition, they’re either already extracted (so the contents are elsewhere) or never opened (so you didn’t need them anyway). Here’s how to find them all.
Smart Folder for archives
The fastest method is a Finder Smart Folder filtered by file type.
Open Finder and choose File → New Smart Folder. Click “This Mac.” Hit the + button.
Change the dropdown from “Kind” to “File extension” — you’ll need to pick “Other…” from the Kind dropdown first, then search for “extension” and select it.
For zip files, type zip. For broader coverage, you’ll need separate criteria for each type. Stack + buttons for: zip, rar, 7z, tar, gz, bz2, tgz.
A simpler approach: change the dropdown to Kind and pick “Archive” — macOS recognizes most common archive types as a group.
Save the folder, sort by Size, and the worst offenders surface first.
Spotlight from the command line
mdfind queries Spotlight more flexibly than the GUI:
mdfind 'kMDItemContentType == "public.zip-archive"'
For broader coverage:
mdfind 'kMDItemContentType == "public.archive"'
That returns archives of all types Spotlight recognizes. To combine with size:
mdfind 'kMDItemContentType == "public.archive" && kMDItemFSSize > 104857600'
Archives over 100MB, which are worth your attention. To make it readable:
mdfind 'kMDItemContentType == "public.archive" && kMDItemFSSize > 104857600' | xargs -I {} du -h "{}" 2>/dev/null | sort -hr
The find command for thorough searching
find reads file extensions directly, useful when Spotlight indexing is incomplete:
find ~ -type f \( -name "*.zip" -o -name "*.rar" -o -name "*.7z" -o -name "*.tar" -o -name "*.gz" -o -name "*.tgz" -o -name "*.bz2" \) 2>/dev/null
That covers the major formats. With sizes:
find ~ -type f \( -name "*.zip" -o -name "*.rar" -o -name "*.7z" \) -exec du -h {} + 2>/dev/null | sort -hr | head -50
Top 50 largest archives in your home folder.
For just old archives:
find ~ -type f -name "*.zip" -atime +180 2>/dev/null
Zip files not accessed in 180+ days. These are the deletion candidates that matter most — large enough to bother with, old enough you’ve moved on.
Where zips and archives accumulate
~/Downloads is the worst by far. Browser downloads, email attachments saved to Downloads, .zip files from Slack and Discord. Most can be deleted without thought.
~/Desktop for people who download to desktop instead of Downloads. Same content, worse for finding things.
~/Documents when you save archives “for later” because they seemed important. Old project zips, exported data, that backup you took before reformatting an external in 2022.
~/Library/Caches/[various] — Some apps cache downloaded content as compressed archives. Software updaters in particular do this.
~/Movies — Compressed video archives, especially from screen recording tools that bundle into a zip on export.
/Library/Mobile Documents/comapple~CloudDocs — iCloud Drive. Be careful here; deleting on one device deletes everywhere.
How to know if you’ve already extracted an archive
The cleanest signal: a folder with the same name as the zip exists in the same directory. project.zip next to a project/ folder almost certainly means you extracted it and the zip is now redundant.
To check from Terminal:
for zip in ~/Downloads/*.zip; do
name="${zip%.zip}"
if [ -d "$name" ]; then
echo "Extracted: $zip"
fi
done
That iterates over every zip in Downloads, checks if a matching folder exists, and lists the redundant ones. Adapt to other directories by changing the path.
For RAR and 7z, swap the extension:
for archive in ~/Downloads/*.rar; do
name="${archive%.rar}"
if [ -d "$name" ]; then
echo "Extracted: $archive"
fi
done
Inspecting an archive before deleting
If you’re not sure whether an old zip is worth keeping, you can peek inside without extracting.
For zip files:
unzip -l filename.zip
That lists contents without extracting. Look at file names — if they’re things like node_modules from an old project or .DS_Store files from a long-deleted folder, the archive is dead.
For tar:
tar -tf filename.tar.gz
For 7z and rar, install p7zip and unrar via Homebrew, then:
7z l filename.7z
unrar l filename.rar
Five seconds of inspection beats opening a 4GB extracted folder you don’t need.
What to keep vs. delete
Always safe to delete:
- Zip files where the extracted folder is right next to them
- App installer zips where the app is already in /Applications
- Old project zips for projects you finished and shipped
- Email attachment zips after you’ve used the contents
- Browser download zips after install/extraction
Think before deleting:
- Backup zips of important data (verify the backup was actually used)
- Archives in iCloud Drive or shared cloud folders (may sync to other devices)
- Source code archives you might want to reference
- Anything in a project folder you’re still actively working on
Don’t touch:
- Archives in /System or /Library you don’t recognize
- Xcode-related .tar files in /Library/Developer
- Archives inside app bundles or packages
The DMG and PKG side note
While not technically “archives” in the macOS classification, .dmg and .pkg files behave similarly — they’re installer wrappers that become redundant after install.
Find them with:
find ~ -type f \( -name "*.dmg" -o -name "*.pkg" \) 2>/dev/null
Or via Smart Folder by Kind: Disk Image. Most Macs have several gigabytes of forgotten installer .dmg files in Downloads alone.
Building a regular sweep
Archives accumulate continuously, but the rate varies. People who download lots of software see new zips weekly. Average users might add a handful per month. Either way, a quarterly archive sweep keeps the count manageable.
Set a recurring reminder. Open your saved Smart Folder. Sort by Size. Top-down: anything you don’t recognize and nothing nearby suggests it’s still relevant — delete.
For people who’d rather automate this, a cleaning tool can flag old archives alongside other deletion candidates in one pass. You still make the final calls, but the catalog work is done for you.
Either way, archives are some of the most satisfying cleanup targets. Each deletion frees a known amount of space (the file size in Finder), nothing depends on them, and the contents either exist already in extracted form or were never needed.