How to Show Hidden Files and Folders Within Ubuntu

Hiding and showing certain files makes for a more tidy browsing session

Linux, by default, hides files from view—even if you have access to those files—if the filename begins with a period. This visual suppression doesn't encrypt the file or make it inaccessible. Instead, it doesn't list hidden files unless you explicitly request these files to be listed. Because of this hide-by-default nature, many configuration files have a period at the beginning of the filename.

Show Hidden Files

In your graphical file manager, use the file manager options to reveal hidden content. Most file managers accept the Ctrl+H hotkey to toggle the hidden-file display on and off. In addition, each file manager uses different buttons and menu commands to toggle the display using the mouse.

In a shell session, modify the ls command with the -a flag to display hidden files:

ls -a
Linux ls -a option

Hide Files

To hide a file, rename it so that the first character of the filename is a period. This approach offers aesthetic convenience only. Don't use this method as a surrogate for proper file security.

In Linux, because any system object is a file, this dot-name approach also works with folders.

Was this page helpful?