How to hide files and folders on Mac — hiding vs. encryption

You can hide a file or folder from normal Finder views with the macOS hidden file flag. This is useful for reducing clutter, but it is not a security feature: anyone who can access the item can reveal it again.

Quick answer

  • Use chflags hidden to hide an item from normal Finder views.
  • Use chflags nohidden to make it visible again.
  • Use encryption—not a hidden flag—when the file contents or names must be protected.

Hide a file or folder with Terminal

  1. Open Terminal from Applications > Utilities.
  2. Type chflags hidden , including the space after hidden.
  3. Drag the file or folder from Finder into the Terminal window. Terminal inserts its exact path.
  4. Press Return.
  5. Close and reopen the Finder window if the item is still visible.

Example:

chflags hidden "/Users/your-name/Documents/Private notes"

Quotation marks are important when a path contains spaces. Avoid sudo and avoid applying the command recursively unless you understand every item it will affect.

Reveal hidden items temporarily in Finder

In an open Finder window, press Command-Shift-. (period) to toggle hidden items. Hidden items appear dimmed while this view is enabled.

Press the same shortcut again when you no longer want Finder to display hidden items.

Make the item visible again

Use the same procedure with nohidden:

chflags nohidden "/Users/your-name/Documents/Private notes"

The built-in macOS command manual documents both flags. Run man chflags in Terminal to read the version installed with your Mac.

What hiding does—and does not do

Method What it does What it does not do
chflags hidden Removes an item from normal Finder views Does not encrypt data or deny access
Finder’s hidden-items shortcut Reveals or conceals hidden items in the current Finder view Does not change permissions or encryption
FileVault Protects the Mac’s internal volume with full-volume encryption and login credentials Does not hide a file from an authorized user in an unlocked session
Encrypted storage such as a SimpleumSafe Safe Encrypts imported file data and protects the Safe with its credentials Does not automatically remove every original file or external copy

Hidden files may still be accessible from Terminal, apps, backups, search tools, or another account with sufficient permissions. Hiding also does not protect an unlocked Mac from malware or remote access.

When to use FileVault

Use FileVault to protect the internal storage of the Mac when it is locked or powered off. On Macs with Apple silicon or the Apple T2 Security Chip, Apple says FileVault key handling for internal storage takes place in the Secure Enclave.

FileVault is the system-level foundation; it is not a per-file hiding tool. Learn how to turn on FileVault.

When to use an encrypted Safe

Use an encrypted Safe when selected files should remain protected separately from the normal Finder hierarchy or when you want encrypted synchronization between your Apple devices.

In SimpleumSafe for Mac:

  1. Open the Safe.
  2. Drag files or folders from Finder into the Safe, or copy them in Finder and paste them into the Safe.
  3. Wait for the import to finish and confirm that you can open the imported item.
  4. Keep a backup. By default, the original outside the Safe still exists; decide separately when it is safe to delete that original.

SimpleumSafe encrypts imported file data and stores the encrypted data under a random identifier that does not reveal the original file name. The Safe’s file attributes are stored in an encrypted database. See How SimpleumSafe works and the Technical White Paper for the product boundaries and implementation details.

Choose the method by your goal

  • Reduce visual clutter: use the macOS hidden flag.
  • Protect the whole Mac at rest: turn on FileVault and use a strong login password.
  • Protect selected files separately: use encrypted storage and remove unencrypted originals only after verifying the encrypted copy and your backup.
  • Prevent other local users from opening a folder: use separate macOS accounts and appropriate permissions; hiding alone is not sufficient.

Sources and further reading