Sometimes you may need to hide a file or folder from your home directory, but without modifying its name (E.g renaming
.example) and also without removing it or moving it somewhere else.
You just want to leave it in the same location, but without seeing it in your file manager view again.
This could be helpful for example in the case of Snaps; They always leave a
snap folder in your home folder while they are working, and you can’t remove it or move it somewhere else, Still, you don’t want to see that damn folder all the time.
You also want to prevent members of your family from searching your sensitive files while you are not close to your computer, but you also don’t want to remove these files 😉
Luckily, there’s a hidden (Quite hidden!) method in which you can do that in just one minute, and on all the major file managers (Not just nautilus).
The method is quite simple. Just create a
.hidden text file in your home directory, and put the name of the files/folders you want to hide in each separate line. So the contents of my own file at
/home/mhsabbagh/.hidden will be:
Then close your file manager and open it again, and you’ll see the folders being hidden:
By our testing, we found that the feature is supported on:
- Nautilus: GNOME’s default file manager.
- Dolphin: Default file manger for KDE.
- Thunar: Default file manager for Xfce.
- Pcmanfm-Qt: Default file manager for LXQt
- Caja: Default file manager for MATE. (Thanks to Mahmut Erogul feedback).
Additionally, the feature works on any folder, and not just the home directory. So say that you want to hide a folder called
something which is located inside
/home/<username>/Downloads, then what you’ll do is that you’ll create a text file named
.hidden in the
/home/<username>/Downloads and put
something inside it, and then restart your file manager.
In this way, you can keep your files and folders located at their place, but without seeing them in the file manager view.
Tell us in the comments if this feature was helpful to you!
Hanny is a computer science & engineering graduate with a master degree, and an open source software developer. He has created a lot of open source programs over the years, and maintains separate online platforms for promoting open source in his local communities.
Hanny is the founder of FOSS Post.
FOSS Post has been providing high-quality content about open source and Linux software for around 7 years now. All of our content is free so that you can enjoy it whenever you like. However, consider buying us a cup of coffee by joining our Patreon campaign or doing a one-time donation to support our efforts!
You can take a number of interesting and exciting quizzes that the FOSS Post team prepared about various open source software from FOSS Quiz.