View every file on your computer
Do you want to see every file on your computer? Maybe there are some files you need that are missing, or maybe you just want to ensure there aren't unfamiliar files on your system. Regardless of your reasons for listing every file on your computer, you can use a command in Command Prompt (cmd) on Windows 10/11 computers to see a list of all files on your hard drive.
Easily List Every File on Your Computer
Open Command Prompt as an administrator, type "cd C:\", and press "Enter" to navigate to the root of your C drive. Type "dir /s" and press "Enter" to list every file on the drive.
Steps
-
Open Command Prompt as an administrator. Type "Command Prompt" in your Start menu and right-click the "Command Prompt" result to open another menu. Select Run as administrator .
-
Navigate to the drive where you want to list all the files. Use the cd command to enter the root of your main drive. For example, if you want to list every file on your C drive, type cd C:\ and press Enter .Advertisement
-
Type dir /s and press ↵ Enter . This will show you every file on the drive in the Command Prompt window. You can also use additional parameters with the dir command to change what you see. Some popular parameters and their uses are:
- dir /s /a:[attributes]
displays files with specified attributes.
- For example, dir /s /a:h lists hidden files, and dir /s /a:d shows directories. [1] X Research source
- dir /s /b shows the files in bare format (no headers or summary).
- dir /s /o:[order]
specifies the order to display the files.
- dir /s /o:n displays files in alphabetical order.
- dir /s /o:d displays files oldest to newest.
- dir /s /o:s sorts files smallest to largest.
- dir /s /o:-s sorts files largest to smallest.
- Enter dir /s /a:hs /q C:\Windows > myfile.txt to send the results to a text file instead of viewing them in the Command Prompt window. You can open that file with Notepad to read it, or you can type type myfile.txt . [2] X Research source
- dir /s /a:[attributes]
displays files with specified attributes.
Advertisement
Community Q&A
Search
-
QuestionHow do I list all of my computer files with Windows 10?Community AnswerFor Windows 10, follow these instructions: Hold the windows key and press "r," type in "cmd" and then press enter, type in "cd ../.." and then press enter, type in "tree" and then press enter. This will usually show all of the files on your hard drive.
Ask a Question
200 characters left
Include your email address to get a message when this question is answered.
Submit
Advertisement
Tips
- If you want to free up space by deleting unnecessary files, you can use Windows Storage Sense to do so easily.Thanks
Submit a Tip
All tip submissions are carefully reviewed before being published
Name
Please provide your name and last initial
Thanks for submitting a tip for review!
Advertisement
References
About This Article
Thanks to all authors for creating a page that has been read 106,190 times.
Advertisement