What they are
- swapfile0, swapfile1…: when apps need more memory than the Mac has, macOS moves less-used memory to these files. They grow and shrink as needed.
- sleepimage: a copy of memory written when the Mac goes into deep sleep, so it can wake with your apps where you left them. It is about the size of your RAM.
See how much swap is used (read-only)
Terminal
sysctl vm.swapusage
ls -lh /private/var/vmDo not delete these files by hand or with a cleaner. macOS recreates them, and removing them while in use can crash apps or lose unsaved work. They are protected for that reason.
What actually reduces them
- Restart. Swap files are cleared at startup.
- Quit memory-heavy apps: many browser tabs, virtual machines, local AI models. Check Activity Monitor → Memory.
- Free disk space elsewhere. Swap needs room to grow; a nearly full disk makes everything slower.
Junk Raccoon skips /private/var/vm entirely and never offers to clean it.
Questions
Can I delete sleepimage on Mac?
You should not. macOS uses it for deep sleep and recreates it; it is about the size of your RAM.
How do I reduce swap on a Mac?
Restart, quit memory-heavy apps, and keep enough free disk space. Do not delete the swap files.
Let the raccoon do it, safely
Junk Raccoon finds this clutter for you, shows every file first, and keeps a one-click way back. Free to download, no account, no ads.
Download for Mac
