Everywhere All articles Download Buy — $19

Where apps hide your files

Finding sleepimage and swapfile

Updated 2026-10-28 · 5 min read

macOS keeps a hibernation file called sleepimage and a set of numbered swap files on your startup disk, in system folders Finder hides. You can list them and read their sizes, but deleting them gains nothing.

The locations

/private/var/vm/sleepimage
/System/Volumes/VM/swapfile0
/System/Volumes/VM/swapfile1 (and so on)

The sleep image is one file. Swap is a numbered series of files that come and go. On the Mac used for this guide (Apple silicon, macOS Sequoia 15.6), sleepimage was 1 GB on a Mac with 16 GB of memory, and each swap file was also 1 GB. /var/vm is the same folder as /private/var/vm, because /var is a link to /private/var. /System/Volumes/VM is a separate APFS volume that macOS mounts just for swap and keeps out of Finder's sidebar.

Any user can list both folders, but the files belong to root with -rw------- permissions, so only root can read them. To see them yourself:

ls -lh /private/var/vm
ls -lh /System/Volumes/VM

Where swap lives can change between macOS versions, so ask the system rather than guessing:

sysctl vm.swapfileprefix
sysctl vm.swapusage

The first prints the path prefix macOS uses for swap files (/System/Volumes/VM/swapfile on the guide Mac). The second prints total, used and free swap, and whether it is encrypted.

Opening the folder in Finder

Finder hides /private. Choose Go > Go to Folder (or press ⇧⌘G) and paste /private/var/vm or /System/Volumes/VM. From Terminal, open /private/var/vm does the same. You will see the files and their sizes, and nothing more: they cannot be opened.

What each file is for

FileWhat it is
sleepimageHibernation data: a copy of memory written to disk so the Mac can restore your session if power runs out during sleep.
swapfile0, swapfile1 ...Overflow for memory. When apps want more memory than the Mac has, macOS compresses what it can and pages the rest out to these files.

The sleep image is governed by a power setting called hibernatemode. Apple's pmset manual page describes three values: 0 (no copy of memory is written, the default on desktops), 3 (a copy is written while memory stays powered, the default on portables) and 25 (memory is powered off and the Mac restores from the disk image). It adds that whether an image is written also depends on the standby and autopoweroff settings. Check yours without changing anything:

pmset -g | grep -E "hibernatemode|hibernatefile"

On the guide Mac this printed mode 3 and a hibernatefile of /var/vm/sleepimage. The file's size is not simply your memory size (1 GB against 16 GB here), and it can differ by Mac and macOS version, so do not expect your number to match.

Swap files are created as needed and removed when memory pressure drops. When this was written the guide Mac had nine of them, and sysctl vm.swapusage reported 9 GB in total, most of it in use. A lot of swap is a sign that the Mac is short of memory for what you are running, not a sign of a fault.

Can you delete them

Do not. Both folders belong to the system, the files are in use while the Mac runs, and macOS manages them itself. Deleting the sleep image by hand is an old tip from older macOS versions, and it frees nothing lasting: while hibernation is on, macOS needs the file and writes a new one.

What actually reduces them:

If you are hunting for free disk space, these files are rarely the best target, and the Storage pane in System Settings > General does not list them by name. Large folders you can actually act on are covered in the related posts below.

Moving them

There is no supported setting for moving swap. For the sleep image, the pmset manual page says hibernatefile may only point to a file on the root volume, so an external drive is not an option, and the same page asks you to use caution. Changing it needs administrator rights. For nearly everyone the right answer is to leave both where macOS put them.

Why a normal search never shows them

Finder and Spotlight searches leave out /private and the hidden system volumes. The files also have no extension and hold no readable content. A search that does not list sleepimage is not a sign that it is missing, only that those searches skip system folders.

Checking them next time

Everywhere deliberately leaves /private/var/vm and /System/Volumes/VM out of its index, as it does the other hidden system volumes, so it will not list these files; the ls and sysctl commands above are the reliable check. Where it helps is the rest of a disk-space hunt: typing a name or extension such as .dmg lists matching files across the folders it covers, and ⌘↵ reveals one in Finder.

Common questions

Where is the sleepimage file on a Mac?

At /private/var/vm/sleepimage, also reachable as /var/vm/sleepimage. Only root can read it, so you can list it with ls -lh /private/var/vm but not open it.

Where are swap files stored on macOS?

On the Mac used for this guide (macOS Sequoia 15.6) they were /System/Volumes/VM/swapfile0, swapfile1 and so on. Run sysctl vm.swapfileprefix to see the prefix your version uses.

Is it safe to delete sleepimage or swapfile?

No. They are system files in use, and macOS manages them. Quitting heavy apps or restarting is the safe way to reduce swap.

Why is my sleepimage so big?

It holds hibernation data, so its size depends on your Mac and settings; on the guide Mac it was 1 GB with 16 GB of memory. Check pmset -g | grep hibernatemode: the manual page gives 3 as the default on portables, which writes the image.

Find any file before you finish typing

Everywhere keeps track of every file on your Mac — including the folders Spotlight hides and drives you have unplugged. Free for a day, then $19 once.

Version 2.20.3 · macOS 13+ · 4.7 MB · notarised

Related

© 2026 Caretopia Network Private Limited Everywhere for Mac Buy a licence Articles Privacy Support