Guide to Check Disk Space Using PowerShell [2024 Tutorial]


Many Windows users want to check their disk space using PowerShell, but they might find it confusing to perform operations. This tutorial aims to introduce multiple ways to check disk space with PowerShell and an alternative tool to show disk usage.

⏱️Duration: 5-10 minutes
🎯Goal: Check disk space with Powershell script on Windows computers
🧰Tools:

Check Disk Space using Powershell

When to Check Disk Space with PowerShell

Here are a few examples of specific situations or symptoms that may prompt you to check your computer's disk space using PowerShell:

If you have experienced any of the situations mentioned above, you can refer to the tutorial in the coming section and check disk space using PowerShell.

How to Check Disk Space in PowerShell [With Pictures]

There are multiple methods available to check the disk space in PowerShell. This section introduces the three most commonly used ways to check your disk space using PowerShell commands. Comparatively, these are less complicated and functional for Windows users.

Way 1. PowerShell Check Disk Space via the Get-Volume Command

Get-Volume is the easiest command to find disk storage information. Using this command, you can check the space details of all the volumes at once. It displays the essential information, including health, system type and free/used space in GB. In addition, we will show how you can check the storage space information of a specific drive.

1) Show All Volumes and space allocation

Step 1: Go to the Search bar and type PowerShell.

Step 2: Select the "Run as Administration" option.

Open PowerShell

Step 3: Type Get-Volume in PowerShell window and hit Enter.

Use Get Volume command in PowerShell to check disk volume space

Now, you will find a list of partitions along with their information.

2) Show a Specific drive

To inquire about the details of a specific drive, such as the C drive, insert the following command: Get-Volume -DriveLetter C. If you want to get the information for another drive, simply replace the drive letter accordingly.

Change drive letter to get disk space of other disk partiton with PowerShell

Way 2. PowerShell Check Disk Space via the Get-PSDrive Command

It is another effective yet simple way to check disk space using cmdlet. Here are two different commands to follow:

# 1. Check the Space of All Drives

This command displays the free disk space of all drives in GB.

Step 1: Open the PowerShell window.

Step 2: Type Get-PSDrive command, and hit Enter to run it.

Get intire disk space

It will display a detailed view of used/free disk space, provider, and root of all partitions in the local drive.

# 2. Check the Space of a Specific Drive

Check the used/free disk space for a particular drive by running the following command: Get-PSDrive C. Replace the latter of the target drive instead of C.

Check specific volume space via powershell

Way 3. PowerShell Get Disk Space via the Get-WmiObject Command

This method is a slightly complicated but practical alternative compared to the earlier-mentioned methods. It provides detailed information about your drives. Two scripts of this method provide detailed information, including media type, drive's total size in GB, and employed/free space.

1) Check Total Allocated Space

Select the following command, copy and paste it into PowerShell, and hit Enter.

Check total allocatd space on hard drive via PowerShell

See the displayed details. You can easily determine the space allocation of all partitions of the local drive.

2) Check the Storage Capacity Assigned to Each Drive

Run the following command to check the detailed space portion of each drive specifically. It shows free/total disk space and the free percentage of each drive in your computer.

All you need to do is drag and drop the given command on PowerShell. See the screenshot to know how it works.

Get storage capacity assigned to each drive in Powershell

Personal Thoughts:
PowerShell is a practical solution for checking disk space, however, it can be challenging for beginners to use. Also, an incorrect command can lead users to unexpected data loss. In short, PowerShell may not be the best option for those who haven't prior experience due to its complexity and difficulty of operation.

If you are a beginner without extensive computing experience or familiarity with PowerShell, we recommend using a reliable third-party tool - Qiling Disk Master. You can take a view of this software in the next part.

Bonus Tip: Check Disk Space with PowerShell Alternative Software

Qiling Disk Master is a popular alternative software to check disk space in minutes. As a free disk space analyzer, it is known for its rich features and appealing interface. It has all the options that drive users to check disk space and free it up easily. For example, by utilizing its Disk Space Analyzer feature, they can view information for individual drives without requiring a scan.

This tool also assist you in checking the total disk space on a newer operating system, such as Windows 11:

related articles

How to Check Total Disk Space in Windows 11

This passage will provide three ways to use a professional disk space analyzer, Windows Setting, Disk Management, and CMD to check hard drive space.

Check Total Disk Space in Windows 11

Qiling Disk Master VS PowerShell, What Makes This Software Stand Out In Checking Disk Space

Here is a comparison table, and you can take a view and learn what makes Qiling Partition Mater with its Disk Space Analyzer feature surpass PowerShell:

Qiling Disk Master
PowerShell
  • Free to analyze disk space
  • Easy to use, support all Windows OS
  • Efficient and fast for all levels of users
  • Bonus features in managing disk space
  • Free
  • Available in most Windows systems
  • For advanced Windows users, not user-friendly for beginners

In addition, Qiling Disk Master is not only a tool for checking disk space but also allows you to manage disk space with the listed features below, including:

A Brief Review of PowerShell

Image of PowerShell

PowerShell is an efficient command-line shell and scripting language tool. It is designed to manage Windows administrator tasks using multiple commands, scripts, and modules. Windows users can perform different tasks, including checking disk space, installing Windows Updates, etc.

PowerShell works seamlessly on all Windows operating systems. Its extensive array of cmdlets provides users with multiple options to execute tasks. For instance, users can choose from several commands to check disk space with PowerShell and can also enhance the level of detailed results by adding different commands. As a result of its versatility, this tool is extensively used by professionals.

If you feel like the provided tips on this page for checking disk space with PowerShell or its alternative tool, share and help more friends around you online:

Conclusion

We hope this tutorial helps you to check and manage your disk space. You are free to opt for any method to get the work done. However, we recommend only advanced Windows users should operate the PowerShell utility. Whereas beginners can employ Qiling Disk Master because it is effortless to operate with any level of expertise.

In addition, we advise you to follow the given tips and manage your disk space more efficiently:

FAQs About Check Disk Space Using PowerShell

Follow our FAQs section to find answers if you have more doubts about checking disk space using PowerShell.

1. What PowerShell script can I use to get the disk space report?

If you want to get the disk space report through PowerShell, run the "Get-PSDrive" script. It will show you information like used/available disk space, total capacity, and used space.

2. How do I check disk space in CMD?

You can CMD to check the disk space. Follow the steps:

Step 1: Open the Windows Search bar, type Command Prompt, and click Rus as administrator.

Step 2: Type wmic diskdrive get size and press Enter.

It will show you the total size of your hard drive.

3. Can I run PowerShell to check disk space on Windows Servers?

Yes, to check the disk space on Windows Servers, run the following command in PowerShell: Get-DiskSpaceReport.

The script will collect information on all the Windows Servers and save it as a CSV file on the local disk. Open File Explorer and navigate the saved file in C:\Temp\DiskSpaceReport.

Related Articles


Is this information helpful?     

What can we do to improve this information? (Optional)
Refresh Please enter the verification code!