• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
Source Digit

Source Digit

Linux, Ubuntu Tutorials & News, Technology, Gadgets & Gizmos

  • Home
  • How To
  • Ubuntu
  • Instagram
  • Blogging
  • Android
  • WordPress
  • +More
    • Cloud Computing
    • Gadgets
    • Social Media
    • Technology
  • Write for Us
Home / How To / How To See Hidden Files And Hidden Folders In Linux

How To See Hidden Files And Hidden Folders In Linux

By Sourabh / September 13, 2022 Category: How To, Ubuntu

Display only hidden files in Linux. Learn how to show hidden files in terminal Ubuntu and how to show hidden folders in Linux command line.

Display the hidden files and directories

To display the hidden files and directories in Linux Ubuntu, use the ls -a command and joining the command with grep to show only the hidden files (all that start with a . (dot)). See below:

$ ls -a | grep "^\."

Once the command is executed it will only show the result which start with a dot (is hidden).

Note that whne you run the above command it is quite hard to tell which is file and which is the folder. To do so, you can see the hidden files and directories in the long listing format.

When you have the result in long listing format you can easily see which is a file and which is a directory.

To see hidden files and folders in long listing format, run the command:

$ ls -ld .*

Display Only Hidden Files

If you want to display only hidden files and do not wihc to see the hidden directories/folders, run the following command:

$ ls -ld .* |grep -v ^d

The ‘ls’ command lists information about files (of any type, including directories).

When you execute ls -a it looks in directories and it does not ignore file names that start with ‘.’.

‘-d’ is for directory and ‘-l’ is for long format or ‘–format=verbose’ where in addition to the name of each file, print the file type, file mode bits, number of hard links, owner name, group name, size, and the modification time.

Primary Sidebar

Latest Posts

Delete Directory And Contents Recursively Without Prompt On Linux

Check User Login History In Ubuntu Linux Command Line

Use Locate Command To Find File In Linux Terminal By Name

How To Change Terminal Color In Ubuntu Command Line

How To Run Fsck Manually In Linux To Fix Unexpected Inconsistency

How To Fix Broken Packages On Ubuntu From Terminal

Re Execute The Previous Command In Linux Ubuntu Command Line

How Much RAM Is Needed For Ubuntu PC

How To Find Large Files And Directories In Linux Command Line

How To Use Clear Command History In Linux Terminal

© 2026 Source Digit • Linux, Ubuntu Tutorials & News, Technology, Gadgets & Gizmos

  • Home
  • About
  • Privacy Policy
  • Terms & Conditions
  • Contact Us
  • Sitemap