Sometimes you need to edit a system file, or look at a file created by one of your programs. Many of these files are hidden by default, so you’ll need to make them visible before you can go about your business. One example I often encounter is hosts files, either for SSH or for your computer’s whitelisted and blacklisted domains, though there are many others.

One quite well known method to view these hidden files is with the Terminal command:

defaults write com.apple.finder AppleShowAllFiles TRUE ; killall Finder

We’ve covered that before and it works well, but it affects the whole file system, and needs the opposite command to undo, which takes time:

defaults write com.apple.finder AppleShowAllFiles FALSE ; killall Finder

With that in mind, let’s look at a quicker way that affects only the current in-focus Finder window.

How to toggle hidden files in the current Finder window

This is so simple it barely merits steps, but what the heck?

1) Select the Finder window showing the contents of the folder you’re interested in.

2) Press the following keys together: cmd + shift + full-stop (period). That is: ⌘ + ⇧ + .

3) Behold your newly-shown files in all their eminent glory.

Once you’ve made your changes, simply press the keys again to re-hide the files.

It quite literally couldn’t be simpler. This is one of those useful tricks that will speed up your workflow once you’ve committed it to memory.

Got another useful tip like this? Want to see another guide from us? Let me know at: joe@idownloadblog.com

  • Michael Scarborough

    This appears to work in macOS 10.12 and 10.13, but it doesn’t work in earlier versions of the OS.

  • Iskren Donev

    That’s nifty! Just note that it needs a Finder window to work. I tried it on my desktop, but it wouldn’t show the hidden files here.

    • Joaquim Barbosa

      Good point! If necessary, you can just open a finder window to show your desktop and then view hidden files that way.