Free guide · no cleanup app required

Clean up your Mac for free.

macOS already includes the tools you need to inspect disk space, caches, logs, running processes, installer receipts, and common developer storage. The commands on this page do not delete files.

First, know what you are looking at

Caches are working copies. Logs are activity records.

Neither is the same as your documents, photos, or project files—but that does not make every item inside automatically disposable.

Cache

A copy kept to make an app faster.

Examples include downloaded images, previews, indexes, and compiled data. Most applications rebuild their caches, so the next launch may be slower and some data may be downloaded again. A poorly behaved app can still put important state in a cache folder, so recovery is never guaranteed.

Log

A record of what an app or service did.

Logs help diagnose crashes, errors, and unusual behavior. Applications usually create new logs after old ones are removed, but the old diagnostic history is gone once Trash is emptied.

Never used Terminal?

Open it in four steps.

Terminal is already installed on every Mac. Open it once, then use the Copy buttons below. You do not need to type the commands yourself.

  1. Step 1

    Press ⌘ Space

    This opens Spotlight Search.

  2. Step 2

    Type Terminal

    Choose the Terminal app, then press Return.

  3. Step 3

    Copy a command below

    Use the Copy button beside the task you want.

  4. Step 4

    Press ⌘V, then Return

    The command runs and prints a result or opens Finder.

Start with Disk capacity and free space below. Every command on this page either reads information or opens a folder in Finder; none deletes a file.

Already decided? Use the fast path

Want all user caches and logs gone?

Quit every application, use the two Copy buttons below, and run each command in Terminal. In each Finder window, press ⌘A to select the contents, then ⌘Delete to move them to Trash. Do not move the Caches or Logs parent folder itself.

OPENS FINDER

Open your cache folder

open "$HOME/Library/Caches"

Quit your applications first. In Finder, select the contents—not the Caches folder itself.

OPENS FINDER

Open your log folder

open "$HOME/Library/Logs"

Logs are diagnostic history. Select the contents—not the Logs folder itself.

This is the aggressive option. Expect slower first launches, possible re-downloads, and lost diagnostic history. Reopen your important apps and verify them while the items are still recoverable from Trash. Empty Trash only after you are satisfied.

Measure first

Start with read-only commands. A large or old file is not automatically disposable.

Use Finder and Trash

Open folders in Finder and move only items you recognize. Trash lets you restore them.

No destructive shortcuts

This guide intentionally contains no sudo, rm, or automatic cleanup command.

The actual cleanup

Move a recognized item to Trash.

Once you know what an item belongs to and have decided you do not need it, the cleanup itself is a Finder action.

  1. Step 1

    Quit the app

    Close the application that owns the cache or log.

  2. Step 2

    Open the folder

    Use an open command from this guide to reveal it in Finder.

  3. Step 3

    Choose one item

    Select only a child file or folder you recognize—not the parent Library folder.

  4. Step 4

    Move to Trash

    Press Command–Delete or choose File → Move to Trash in Finder.

  5. Step 5

    Verify first

    Reopen the app and check your work before emptying Trash.

01 · Start here

See where your disk space went

These commands report disk usage. They do not delete or move anything.

READ ONLY

Disk capacity and free space

df -h /

Shows the startup disk in human-readable units.

READ ONLY

Largest folders in your Home folder

du -hd 1 "$HOME" 2>/dev/null | sort -h

May take a while on a large Home folder. Permission-blocked paths are omitted.

READ ONLY

Measure one folder

du -sh "/path/to/folder" 2>/dev/null

Replace /path/to/folder with a path you want to inspect.

02 · Common storage

Inspect caches and logs

Measure first, then open the folders in Finder. Do not move the entire Caches or Logs folder itself.

READ ONLY

Measure your caches and logs

du -sh "$HOME/Library/Caches" "$HOME/Library/Logs" 2>/dev/null

Reports the observed size of the two folders without changing them.

OPENS FINDER

Open your cache folder

open "$HOME/Library/Caches"

Finder opens the folder. Nothing is selected or moved automatically.

OPENS FINDER

Open your log folder

open "$HOME/Library/Logs"

Quit the related application before moving one of its recognized folders.

READ ONLY

List cache files older than 30 days

find "$HOME/Library/Caches" -type f -mtime +30 -print 2>/dev/null

Age alone does not mean a file is junk. This can print a long list.

Caution: A folder named Cache can still contain active state. If you do not recognize the owning application, leave it alone.

03 · Files you control

Review Downloads and Trash

These are often the simplest places to recover space because the decision belongs to you.

OPENS FINDER

Open Downloads

open "$HOME/Downloads"

Sort by Size or Date Last Opened in Finder and review the files yourself.

READ ONLY

List Downloads older than 90 days

find "$HOME/Downloads" -type f -mtime +90 -print 2>/dev/null

This is only an age filter. It does not determine whether a file is important.

READ ONLY

Measure Trash

du -sh "$HOME/.Trash" 2>/dev/null

Files in Trash still use disk space until Trash is emptied.

OPENS FINDER

Open Trash

open "$HOME/.Trash"

Review or restore items before emptying Trash.

04 · Activity

See what is running and using a file

Process lists are observations, not instructions to terminate anything.

READ ONLY

List running processes

ps -axo pid,ppid,%cpu,rss,comm

RSS is reported in kilobytes. Helper processes may belong to a larger application.

READ ONLY

Find processes with a file open

lsof "/path/to/file"

Replace the example path. No output usually means no matching open handle was observed.

06 · Developer and AI storage

Measure common developer stores

The commands below inspect tools only when those tools or folders exist. They do not prune images, models, packages, or environments.

TOOL REQUIRED

Homebrew download cache location

brew --cache

Requires Homebrew. This prints the cache path; it does not clean it.

TOOL REQUIRED

Homebrew download cache size

du -sh "$(brew --cache)" 2>/dev/null

Requires Homebrew. Measure the result before deciding what to do.

TOOL REQUIRED

Docker disk usage

docker system df

Requires Docker. Volumes may contain databases or other working data.

TOOL REQUIRED

Installed Ollama models

ollama list

Requires Ollama. Models are working assets, not automatic cleanup candidates.

READ ONLY

Ollama storage size

du -sh "$HOME/.ollama" 2>/dev/null

Reports the observed size of Ollama's local folder when present.

READ ONLY

Hugging Face storage size

du -sh "$HOME/.cache/huggingface" 2>/dev/null

May include downloaded models, datasets, references, and incomplete transfers.

READ ONLY

Xcode and Simulator storage

du -sh "$HOME/Library/Developer/Xcode/DerivedData" "$HOME/Library/Developer/CoreSimulator" 2>/dev/null

Simulator storage can contain app data. Treat it as working data until reviewed.

READ ONLY

npm and pnpm storage

du -sh "$HOME/.npm" "$HOME/Library/pnpm/store" 2>/dev/null

A missing path is simply omitted. Project dependencies live elsewhere too.

Caution: Do not run Docker prune, model removal, package cleanup, or Xcode deletion commands until you understand what will be rebuilt and what cannot be recovered.

The limit of a command

A result is not a verdict.

du can report that a directory occupies 17 GB. It does not prove who owns every file, whether some storage is shared, whether another application is using it, or whether all 17 GB would become free.

find can match a name or age. A matching name is not ownership evidence, and age is not proof that a file is junk.

If you recognize the item and understand the consequence, use Finder and Trash. If you do not, stop. Keeping an uncertain file costs less than losing working data.

If you would rather not do this by hand

The hard part is not the commands. It is deciding.

Everything above is free and always will be. What it cannot give you is a second opinion: the same folder can be a rebuildable cache on one Mac and active working state on another. CleanDeck scans the same locations and labels each item Ready, Review first, or Protected — showing the path and the reason before anything moves. It moves items to the Trash rather than deleting them, asks for no sudo password, installs no background daemon, and keeps what it finds on your Mac.

See what it costsOne-time purchase · 7-day refund · Apple signed and notarized

Share the free guide

No account. No download. No subscription.

Apple Terminal guide