Skip to content

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.

A screenshot showing the WhatsApp gallery in an Android phone.
WhatsApp’s in-built Gallery

Though it does a good job of finding media 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.

For example, images that another app has downloaded to your storage or images from your E-Book covers or album covers. Also, it could be private stuff that you probably don’t want to see every time you launch the gallery.

Fortunately, you can hide such media from the WhatsApp gallery using one of two options:

  • Hide the media by using a .nomedia file; or
  • Hide entire media folders by renaming them

On the other hand, you may consider using the WhatsApp Private folder option if you only need to hide photos and videos that you receive through WhatsApp.

Option 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 file manager, go to its settings and enable to show hidden files/folders.
    A screenshot the file manager settings.
  2. Next go to your primary storage and open the WhatsApp folder then Media Folder.
    A screenshot showing the path to WhatsApp's media folders on a file manager.
  3. In the media folder, open the WhatsApp Voice Notes folder, and you should find a .nomedia file there.
    A screenshot showing a nomedia file in a file manager
  4. Select that .nomedia file, copy it then just paste it inside the folder that you want to hide from the gallery.
    A screenshot showing a nomedia file inside a folder with images.
  5. Open the default gallery app or WhatsApp’s gallery, and you should find the folder is no longer listed.

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.

Option 2: Completely Hiding the Folder

If you don’t mind hiding the entire 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 including WhatsApp don’t scan hidden folders (not unless they’re explicitly told to do so in apps such as MX Player).

To do this:

  1. Open your file manager, go to its settings and 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 for instance if it’s named images rename it to .images. That’s Android’s way of hiding folders and files.
    A screenshot showing a rename dialog for a folder in a file manager on an Android phone.

3. Now open the default gallery app or WhatsApp’s gallery, and you should find the folder is no longer listed.

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.

Tags:
Share:

8 Comments

  1. It hides it in gallery butt it still shows up when i open images through setting up status in whatsap or instagram..

  2. There are no attributes. Android uses a linux file system, and all files beginning with . are hidden by default.
    How the file is created is definitely irrelevant. What you might be experiencing above is that copying the original triggers a database update in android’s media scanner.

    Just create the .nomedia files with anything at all, and then look for the android system app called “Media Storage” and delete its data to force it to rebuild its cache. The .nomedia will then take effect.

    Note, if you happen to use linux, you can load an sdcard and run the following in a folder to do your entire music collection (or whatever) and all its subfolders in one hit:
    find . -type d -exec touch {}/.nomedia \;

  3. I’m so glad i found this article!!! It helped me fix the mess!!

    A DETAIL: it worked after i reseted my phone

Leave a Reply to Eddie Cancel reply

Feel free to share your comments or questions with me. I may not be able to respond immediately so please check later once I've approved your comment.

Your email address will not be published. Required fields are marked *

Kelvin Kathia

Kelvin Kathia is a writer that's passionate about sharing solutions to everyday tech problems. He's the founder and editor of Journey Bytes, a tech blog and web design agency. Feel free to leave him comments or questions regarding this post, or by leaving him a message on the contact page. If you found his content helpful, a donation is much appreciated.