How to Hide Media Folders in WhatsApp's Gallery on Android

WhatsApp comes with an in-built gallery that allows you to pick photos or videos in your storage to share or post. And since it's a gallery, it will scour your entire phone for folders that have images or videos and list them there.

Actually, it's not WhatsApp that's doing all these scouring but the Android Media scanner (i.e. Media Storage) that handles that.

Consequently, whatever you see in WhatsApp's gallery is a carbon copy of what's available in the stock gallery. Go ahead and check.
whatsapp gallery
WhatsApp's in-built Gallery

Though it might do a good job finding stuff we may want to share, quite often it will include folders that we don't want there at all, resulting in a huge clutter of a mess. So it could be stuff that some app has downloaded to your storage or images from your other stuff such as book covers or album covers as it's my case.

Also it could be private stuff that you probably don't want to see every time you launch the gallery. If that sounds like you, then you've come to the right place.



1. Hide Media Using a .nomedia File


A .nomedia file is simply something that tells an app to not look into a particular folder for any kind of media, be it images, videos or audio files. The Android media scanner and other media apps do respect this and simply ignore such folders.

To create a .nomedia do the following:

1. Open your (stock) file manager, go to its settings and enable to show hidden files/folders.
hidden files
Show Hiddn Files and Folders

Note
  • If your phone doesn't have a stock file manager, you can use Android's in-built file manager (Android 6.0 and later) that is available under Settings > Storage & USB > Storage > Explore.
  • You can also just use any file manager from the play store but I can't guarantee it will work.
android explore
Path to Android's File Manager

2. Next go to your primary storage and open the WhatsApp folder then Media Folder.
whatsapp folders
Path to WhatsApp Folders

3. In the media folder, open the WhatsApp Voice Notes folder and you should find a .nomedia file there.
.nomedia file
.NOMEDIA File

4. Select that .nomedia file and copy it. Next, just paste it in the folder that you wish to hide from the gallery.
copying
Copying and Paste the File

5. Open the stock gallery app or WhatsApp's gallery and you should find the folder is no longer there.


Why not just create a .nomedia file?

Well you can. It’s just that I realized that Media Storage tends to ignore some .nomedia files created by some file managers. And since I don't know which exact File Manager you are using, this is my way of ensuring it works for you in light of that possibility.



2. Completely Hiding the Folder

If you don't mind hiding the folder so that it's visible only when show hidden files/folders is enabled, then this is for you. This is guaranteed to work as media storage and other media apps don't scan hidden folders (not unless they're explicitly told to do so e.g MX Player) .

1. Open your file manager, go to its settings and first enable to show hidden files/folders.

2. Go to the folder you wish to hide from Gallery and rename it so that it starts with a dot [.]. So if for instance if its named images rename it to .images. That's Android's way of hiding folders and files.
hiding folder
Rename to Start with a Dot

3. Now open the stock gallery app or WhatsApp's gallery and you should find the folder is no longer there.

So basically that's it. It should go without saying that this is not a secure way of hiding stuff from prying eyes. If that is your primary concern, consider using folder/gallery lock apps or encrypting them with a strong password.

Kelvin is a writer and registered nutritionist based in Nairobi. Passionate about writing and helping people solve problems, he's been actively blogging since 2014 on tech, nutrition and "pseudo poetry".



Recommended Posts



Loading comments...