Where to save your temporary files on macOS

Simon Howard
Jul 25, 2017 · 2 min read

Inspired by this article showing how to change where macOS saves your screenshots, here’s a trick of my own.

I often find myself wanting to save things that I just want temporarily. Tomorrow I won’t need it any more, but maybe I just want to download an image to edit and re-upload it, or download a WAD from the idgames archive. MacOS provides a “Downloads” folder, but such folders have a habit of filling up with random cruft over months; often I only want things for less than a day.

Fortunately, like every Unix-like system, MacOS provides a temporary directory, which files will be automatically deleted from. But it doesn’t expose this in the UI. Fortunately it’s easy to do so.

Open Finder, and choose “Go to Folder…” from the “Go” menu:

“Go to Folder…” allows you to use the Finder to access arbitrary Unix paths which it usually hides.

Then type “/tmp” and click “Go”:

The temporary directory will now be shown; it will probably already contain some things you shouldn’t need to worry about. Click “Add to Sidebar” from the “File” menu, and you should see “tmp” now appears in the Finder and any file dialogs.

Now, whenever you save a file from the Internet, if you don’t think you’re likely to keep it longer than a day, just save it to “tmp”. Similarly if you want to open a file from inside an application, you can just navigate to “tmp” to find the file you saved. Just remember that anything in there will get automatically deleted!

Written by

Filled with the Code of Doom. PGP: [...] F6C2 EE9C 2335 4344

Welcome to a place where words matter. On Medium, smart voices and original ideas take center stage - with no ads in sight. Watch
Follow all the topics you care about, and we’ll deliver the best stories for you to your homepage and inbox. Explore
Get unlimited access to the best stories on Medium — and support writers while you’re at it. Just $5/month. Upgrade