What compressed memory means on a Mac, and why 3 GB of it is fine
macOS compresses memory it is not using right now instead of writing it to disk. Ours held 6.4 GB of data in 3.1 GB of compressed memory. How it works.
What is compressed memory?
When memory runs short, macOS takes pages that apps have not touched for a while and compresses them in memory instead of writing them to disk. Compressing and decompressing is much faster than reading back from the SSD, so it is the first thing macOS does before it swaps.
How much is compressed on our Mac?
| Reading from vm_stat | Pages | Size at 16 KB a page |
|---|---|---|
| Pages stored in compressor | 411,080 | 6.4 GB of original data |
| Pages occupied by compressor | 201,014 | 3.1 GB of memory used |
| Compressions since start up | 435 million | |
| Decompressions since start up | 378 million |
6.4 GB squeezed into 3.1 GB: about two to one, freeing 3.3 GB on an 8 GB Mac.
vm_stat | grep -i compressIs a lot of compressed memory bad?
Not on its own. It is macOS making room. It becomes a problem when memory pressure stays yellow or red and swap keeps growing; see memory pressure.
See it live
Free Mac's System tab reads processor, memory, network and battery once a second, with the busiest processes ranked below, and every tile opens into detail. See also swap used.
Related: Wired memory explained and Load average explained.
Common questions
What is compressed memory on a Mac?
Memory macOS has compressed in place instead of swapping to disk. It is faster than swap.
How much compressed memory is normal?
On our 8 GB Mac, 3.1 GB held 6.4 GB of data. Gigabytes is normal on a busy Mac.
How do I see compressed memory in Terminal?
Run vm_stat and look at pages stored in and occupied by the compressor. Multiply by the page size.