Who wants to see everything everywhere all the time? On a Mac, you don’t have to hide folders inside other folders, though. Find out here how to hide a folder on a Mac right in place (say, the desktop) instead, and how you can still open hidden folders.
First, It’s 1973, and Files Are Showing Up Everywhere
The file system for the Unix operating system had just learned a hierarchy, and two files were created to help navigation:
.lets you refer to the current directory and
..to the one that is its parent.
As useful as they were, their showing up everywhere annoyed Unix’s creators—so they quickly hid all files starting with a dot.
That, for what it’s worth, is the story one of the collaborators then, Rob Pike, tells, and it is why you can still hide files and folders with dots on macOS—a distant descendant of Unix—today:
How to Hide a Folder on a Mac
Time needed: 3 minutes.
- In Finder, click on the folder you want to hide with the right mouse button.
- Select New Terminal at Folder from the context menu that has appeared.
cd ..(two dots) at the command prompt.
Why: This command takes us to the encompassing folder, which will let us modify the current one.
- Press Enter.
- Now type
mv <folder name> .<folder name>(a dot directly in front of the folder name), replacing <folder name> with the name of the folder to be hidden in Finder.
Example: To hide the folder called “Hidden”, type
mv Hidden .Hidden.
Less typing: Profit from folder name auto-completion.
2. Type the start of the folder’s name.
3. Press Tab to auto-complete it.
4. Repeat the previous two steps to quickly get to
mvfollowed by the folder name twice.
5. Press Esc
B(this jumps to the beginning of the last word; if your folder name includes whitespace, repeat until you are at the beginning of the folder name).
6. Add the
- Hit Enter.
- Watch the folder disappear in Finder.
Accessing hidden folders: You can still open hidden folders in Finder—though you cannot normally see them.
Folder flag alternative: Renaming the folder to start with
.will hide it both in Finder and in Terminal; you can also hide the folder only in Finder using an attribute; see below.
Hide a Folder from Mac Finder Using an Attribute
To make a folder disappear from Finder without renaming it:
- Open Terminal.
- Drag and drop the folder you want to hide from Finder into the Terminal window.
Example: After dropping the ~/Documents/Hidden folder, the command line will read
chflags hidden ~/Documents/Hidden.
- Press Enter.
- Watch the folder disappear from Finder (but not from the
lscommand in Terminal, for instance).
Open hidden folder: Here, too, you can still open the hidden folder in Finder if you type its full path.
How to Hide Folders on a Mac: FAQ
How do I unhide a folder?
To make a folder visible again:
- Reverse the process used to hide it.
Example: Type and run
mv .Hidden Hiddento unhide the Hidden folder.
To reveal a folder hidden with the attribute:
chflags nohiddenfollowed by the folder to unhide in Terminal.
chflags nohidden ~/Docments/Hiddento unhide the Hidden folder.
Can I hide a folder on the Mac Desktop?
Yes. The default path to your Mac Desktop is “~/Desktop”, and you can hide folders on it.
Find will not let you rename a folder to a name that starts with a dot, and it will not create folder so named.
Are there any other ways to hide folders on a Mac?
Yes, you can employ a number of third-party tools to hide folders.
(How to hide a folder on a Mac tested with macOS Monterey 12.3, Big Sur 11.0 and Catalina 10.15; updated September 2022)