By Ellie / Last Updated March 8, 2022

How do I check my hard drive space remotely?

“I require a PowerShell script that returns the drive letter, drive capacity, drive usage, and free space for a networked remote server. How can I accomplish this using only my local laptop?”

Two options to check disk space remotely using PowerShell

Here in this part, we introduce two ways to teach you how to check disk space remotely using Windows Powershell. Depending on whether you want to check disk space through a GUI interface, you can choose to use PowerShell directly from your local computer or to access your remote computer using remote desktop software and then check disk space within your remote computer.

Option 1. Use PowerShell from the local computer

Step 1. Right-click Start, and then choose Windows PowerShell (Admin).

Windows PowerShell Admin

Step 2. Type in the following cmdlet and then press Enter, then you can see the size and free space of your disks.

Get-WmiObject Win32_LogicalDisk -ComputerName remote_computer -Filter DriveType=3 | Select-Object DeviceID, FreeSpace, Size 

Replace the remote_computer with the computer name of your remote computer.

Disk Size Command

If you feel this is not intuitive enough, you can also run the following cmdlet to list the size in GB format.

Get-WmiObject Win32_LogicalDisk -ComputerName remote_computer -Filter DriveType=3 | Select-Object DeviceID, @{'Name'='Size (GB)'; 'Expression'={[math]::truncate($_.size / 1GB)}}, @{'Name'='Freespace (GB)'; 'Expression'={[math]::truncate($_.freespace / 1GB)}}

Also, remember to replace the remote_computer with the computer name of your remote computer.

Disk Size Command GB Format

Option 2. Use remote desktop software AnyViewer

The second option is to use AnyViewer, a free and simple remote desktop software that allows you to view a remote computer and operate it as if you were sitting in front of it. The procedure is separated into two stages. To begin, use AnyViewer to gain remote access to the other computer. Second, you may begin remotely checking disk space with PowerShell.

Download Freeware Win 11/10/8.1/8/7
Secure Download

Step 1. Download, install, launch AnyViewer on both your home and office computers.

Connect

Step 2. Go to Log in, and then click Sign up. (If you already have signed up on its official website, you can log in directly.)

Log in AnyViewer

Step 3. Fill in the signup information.

Sign Up for AnyViewer

Step 4. Then you can see you successfully logged in to AnyViewer. Your device will automatically be assigned to the account you've logged in to.

Free Editions

Step 5. Log in to the same AnyViewer account on the two devices, then click Remote control to achieve unattended remote access.

Connect to My Devices

Note: If you upgrade your account to a Professional or Enterprise plan, then you’ll have more rights. You can assign more devices. Also, you can connect to another computer in privacy mode, which means you can black the screen and block the mouse and keyboard of the remote computer.

Step 6. Then you can see the screen of your office computer and take full control of it.

Remotely Control Another Computer

Step 7. Press Win + R, and then type in "diskmgmt.msc" to open Disk Management.

diskmgmt.msc

Step 8. Then you can see your disk spaces.

Disk Management

Conclusion

This post mainly introduces two ways to use the PowerShell command to check disk space on a remote server. If you have the need to check disk space remotely using PowerShell, you can follow the detailed steps we introduced in this post to get started. By the way, if you choose option 2, you can also do many other operations on your remote computer, not only just to check disk space.