MacOS – How to hide a local disk in Finder at root level

finderhard drivemacos

I want to hide some local disks from left pane (Devices section) in Finder.

  • I want to remove them from the list of all disks at root level.
  • What is the command in terminal?

PS: I can't unmount them because they must be accessible for the system.

Best Answer

Here you go

/usr/bin/SetFile -a V /Volumes/Macintosh\ HD

You will need to get the command line tools installed from Xcode if your system lacks the setfile program.