I'm creating a mobile app which has a kind of open file browser or dialogue if you will.

Should i use a filter so only files supported by the application (.txt, .pdf, .epub) are visible or should i display all files?

Has their been any studies on this matter? Please provide sources with your answer.

EDIT: Just to clarify; The unsupported files can not be opened by the application. They are "disabled" in the sence their background does not highlight on touches and "nothing" happens when you touch them.

3 Answers 3


Some desktop applications show all of the files, not only the ones compatible. The compatible ones have full alpha and the "incompatible" ones are greyed out but can be selected as well (although this is also different in some programs). Whether you want to do it like that or not display them at all depends on the way your app can handle those files.

If I open a file with a different extension or no file extension at all, will your app crash or will it try to really read the data in file? On OSX, for example, I can export iwork documents as pdf and the resulting files do not have a file extension (by default, I can manually change that in the export dialog).

The question whether to show or not to show those files in the open file dialog is if you app can handle those files correctly (detecting that it is a pdf, for instance, and act accordingly). If your app is not capable of such behavior and will prompt an error when the user selects such a file, then leave them out in that dialog completely.

It is bad practice to offer choices to the user that will end in error during the next step if that is predictable. If you need to do it that way, put a help text in that dialog explaining that only files with extensions x, y and z are displayed. Better way (in my eyes) is to change the app to be able to handle the files correctly, even without file extension. Then, of course, all files should be visible in the open file dialog.


No studies sorry, just general practice.

There is no use allowing someone to open a file type that is not supported by the app. It would only lead to an error message or something worse.

Still there is a case to be made for the "all files" option, provided that in this case "all" in fact means "all supported". I personally hate it when I first have to select the correct file type before seeing the files of that type. Others prefer it that way.

So, I'd get the best of both worlds and keep everybody happy:

  • Add a filter to the open dialog for each supported file type and
  • add a "All (supported) files" filter at the bottom of the filter list.
  • Make the file type that will be used most often the application default, and
  • change the default with the last file type used on a per-user basis.
  • This and add a search box. Problem solved!
    – Barfieldmv
    May 14, 2012 at 13:27

Since the filters used in a file dialog are based on extension and not the actual header of the file's content, some compatible files will not pass file extension based filters.

Always give the user an option to select only from recognized extension and an option to select any file (by selecting the "all files" filter or by typing *.* into the filename box and pressing enter.

Since the most common and most fool proof option is to filter by the default extensions, this should be the default display.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.