MainspringGuides › purge command
macOS Guide

The purge Command on Mac: Does Freeing RAM Help?

Updated July 2026 · 3 min read

Search "Mac running slow" and someone will tell you to run sudo purge — the memory graph clears, green everywhere, problem solved. Except it isn't. purge does one narrow thing, it almost never makes a Mac faster, and it usually makes the next minute slower. Here's what it actually does and the two cases where it earns its keep.

What purge actually does

# flush the filesystem cache (asks for your password)
sudo purge

macOS keeps recently read files cached in RAM — the file cache — so that opening them again skips the disk entirely. purge throws that cache away. Apple's own manual describes it as forcing the disk cache to be flushed to approximate a cold boot: afterwards, the system behaves as if it just started up and nothing has been read yet.

That's the whole trick. It doesn't compact memory, close leaks, or quit hungry apps. The "used" memory that vanishes from Activity Monitor was cached files — data macOS was holding precisely because it was cheap to keep and instant to reuse. There's no undo command, and none is needed: the cache rebuilds automatically as you use your Mac, which is also why the effect evaporates within minutes.

Why it doesn't speed anything up

The intuition behind running purge is that free RAM is good, so more free RAM is better. Modern memory management works the other way: free RAM is doing nothing for you. RAM holding cached files costs nothing — the moment an app needs that memory, macOS discards cache instantly to make room. Cache is never the thing squeezing your apps.

So after a purge, you get a prettier graph and a real cost: every file the cache was holding — app resources, libraries, documents — now has to be read from disk again. Launches and switches get momentarily slower. If your Mac genuinely feels sluggish, the number that matters is memory pressure in Activity Monitor's Memory tab: green means RAM isn't your problem at all; yellow or red means too much active memory demand, which purge cannot fix — only quitting or taming the apps responsible can.

When purge is genuinely useful

It exists for developers and testers, and it's good at two jobs:

If you're doing either of those, purge is the right tool. If you're trying to make Safari feel faster, it's a placebo with a hangover.

What to do instead when RAM is tight

  1. Open Activity Monitor → Memory and check the Memory Pressure graph — only act if it's yellow or red.
  2. Sort by the Memory column and quit the top offenders you're not using (browsers with 40 tabs are the usual suspects).
  3. Watch Swap Used — consistently high swap on a busy Mac is the honest signal that more physical RAM would actually help.

A note on expectations if you run it anyway: purge needs administrator rights, takes several seconds on a busy Mac, and the number it deflates is the Cached Files figure in Activity Monitor's Memory tab — watch it before and after and you'll see exactly what was discarded, then watch it climb back as you work. Swap is untouched; purge has no effect on it.

Skip the placebo tweaks

Mainspring sticks to settings that do something: 90+ real macOS tweaks — Finder, Dock, keyboard, power — as labelled toggles, each reversible with a click.

Try Mainspring free →

Signed & notarized by Apple · 1-day free trial · $29 once

Read the right graph

Memory pressure — not free gigabytes — is the number that decides whether RAM is your bottleneck. Our guide to understanding memory pressure on Mac explains how to read it.