Guide: How to Count Files/Sub­fold­ers Inside a Folder

Even though I moved my data to Google Drive, I still have a lot on my hard drive. It is annoying to check the subfolders and files in the root directory. I am sure we have all encountered this situation at some point. This can be tricky, especially if there are many subfolders in subfolders with files stored in them. You cannot count them manually. Too cumbersome and boring! To combat this problem, I will share with you some methods to find not only the total number of subfolders in a folder, but also the total number of files in it. Let’s start.

1. View properties

This is probably one of the easiest methods of knowing what’s in that folder. You don’t need any additional software for it either. Just find the folder or subfolder for which you need to count the subfolders or files, right click on it and then click Properties in the context menu. You can also press ALT + Enter to open the properties of a folder or subfolder.

Depending on the make and model of your computer and the size of the folder, it may take a while for Windows to calculate. When it is done, you can view the total size of the primary folder, the subfolders in it and the number of files in those folders and subfolders. Note: There is an option to count hidden files and subfolders as well as shown in the screenshot above. If you haven’t hidden them manually, I recommend that you don’t play around with this setting.

2. Use File Explorer

File Explorer allows you to browse all files and folders on your hard drive. You can start it directly by pressing the Windows Key + E shortcut or go to My Computer and select the appropriate partition. File Explorer can also be used to quickly find the number of subfolders or files in a given folder. Open the folder and select all subfolders or files manually or by pressing CTRL + A. If you choose manually, you can select and omit certain files.

You can now see the total number at the bottom left of the window. Repeat the same for the files in a folder and subfolder. This is useful when you want to know the total number in a particular folder.

3. Command Prompt

Quite a few Windows users enjoy using the command prompt. It can be a powerful tool, if you know it how to use it and remember the correct commands. This one is for those using the command prompt. Press the Windows key and type RUN to open the Run dialog box. Type cmd and hit enter to launch command prompt.

You will see a new window with a black background and white text. Now you have to enter the path where the folder is located. First, I’ll be using the CD command to change the drive from C to H as the command prompt opens by default to point to the C drive. I type CD / to go back to the root of C Drive and type the drive letter with a colon (H 🙂 to change the drive. Then enter the folder path preceded by the CD command to open the folder you want.

As the CD command is used to change directories, the DIR command is used to work with directories. Type the following command to count all files and subfolders in a parent folder or directory. dir *. * / w / s

Don’t worry if you see the text scroll automatically. Finally, you can see the total number of files and folders (subfolders) in the primary folder. That includes all files and directories since the command is recursive.

4. PowerShell

Are you feeling a bit geek? For advanced users, there is the PowerShell which is a step up from what we saw with the command prompt when it comes to difficulty. Use the Windows search function feature to find and click Windows PowerShell.

You will see a new window appear up with a blue background this time. Navigating to the folder you want is easier in the PowerShell. Just type cd followed by your directory structure. cd h: database

Copy and paste the following command to count all files or subfolders in the parent folder. Get-ChildItem | Measurement object | % {$ _. Count} You will notice that the result I got above is different. This is because the command is not recursive, which means it doesn’t go deeper than one level. So there are 5 subfolders.

To count all files and folders recursively: Get-ChildItem -Recurse | Measurement object | % {$ _. Count} To count only directories recursively: Get-ChildItem -Recurse -Directory | Measurement object | % {$ _. Count} Only count files recursively: Get-ChildItem -Recurse -File | Measurement object | % {$ _. Count}

5. WizTree

Finally, let’s take a look at software that not only makes life easier, but also helps you understand the type of files you have in the folder. WizTree is a hard drive analyzer that collects many data statistics such as file extensions and their respective number, space occupied by each format and individual files and folders.

If you click on the little ‘+’ icon next to a folder, you will see the tree structure with their individual details. So you can easily browse the hierarchy of the folders and subfolders without having to go back and forth between the folders. Download WizTree

Know the count

As discussed above, there are quite a few ways to count the number of files and folders or sub-folders in the root directory. Depending on your needs, you can opt for the built-in Windows Explorer or the more powerful WizTree software that also shares other details in a tree-like structure. The next up: Do you use Skype on Windows 10? Learn how to record Skype calls for important meetings or conversations.

How to Count Files/Sub­fold­ers Inside a Folder: benefits

Faq

Final note

I hope you like the guide How to Count Files/Sub­fold­ers Inside a Folder. In case if you have any query regards this article you may ask us. Also, please share your love by sharing this article with your friends. For our visitors: If you have any queries regards the How to Count Files/Sub­fold­ers Inside a Folder, then please ask us through the comment section below or directly contact us. Education: This guide or tutorial is just for educational purposes. Misinformation: If you want to correct any misinformation about the guide “How to Count Files/Sub­fold­ers Inside a Folder”, then kindly contact us. Want to add an alternate method: If anyone wants to add more methods to the guide How to Count Files/Sub­fold­ers Inside a Folder, then kindly contact us. Our Contact: Kindly use our contact page regards any help. You may also use our social and accounts by following us on Whatsapp, Facebook, and Twitter for your questions. We always love to help you. We answer your questions within 24-48 hours (Weekend off). Channel: If you want the latest software updates and discussion about any software in your pocket, then here is our Telegram channel.

How to Count Files Sub fold ers Inside a Folder 2021  2022  - 45How to Count Files Sub fold ers Inside a Folder 2021  2022  - 25How to Count Files Sub fold ers Inside a Folder 2021  2022  - 62How to Count Files Sub fold ers Inside a Folder 2021  2022  - 63How to Count Files Sub fold ers Inside a Folder 2021  2022  - 97How to Count Files Sub fold ers Inside a Folder 2021  2022  - 97How to Count Files Sub fold ers Inside a Folder 2021  2022  - 21How to Count Files Sub fold ers Inside a Folder 2021  2022  - 85How to Count Files Sub fold ers Inside a Folder 2021  2022  - 20How to Count Files Sub fold ers Inside a Folder 2021  2022  - 27How to Count Files Sub fold ers Inside a Folder 2021  2022  - 89How to Count Files Sub fold ers Inside a Folder 2021  2022  - 32How to Count Files Sub fold ers Inside a Folder 2021  2022  - 54How to Count Files Sub fold ers Inside a Folder 2021  2022  - 61How to Count Files Sub fold ers Inside a Folder 2021  2022  - 98How to Count Files Sub fold ers Inside a Folder 2021  2022  - 10