How to Extend Partition Remotely [Two Methods]

How do I extend partition remotely on my computer? To help you work out this problem, we introduce two methods to you. You can use PowerShell script to extend disk space remotely or use the remote desktop software.


By Ellie / Updated on August 2, 2023

Share this: instagram reddit

How do I extend a partition on my computer remotely?

“I need to extend the existing C disk on a remote computer. How can I accomplish this timely and efficiently? I attempted to use a PowerShell script but was unsuccessful. I’m not sure what I was doing incorrectly. Any suggestions? Thank you very much in advance!

-Question from Quora"

Two methods to extend partition remotely

Here in this part, we’ll introduce two methods to help you extend partition remotely. One is to use the PowerShell script to check disk space and extend disk space on the remote computer. Another is to use the remote desktop software to access another computer and then extend the disk partition remotely.

Method 1. Extend partition remotely using PowerShell

Before starting, you need to know that PowerShell remoting is enabled by default only on Windows Server 2012. Therefore, to use PowerShell to extend partition remotely, you need to first enable PSRemoting on the remote computer if it is other supported versions of Windows. Otherwise, the command won’t work.

Step 1. On the remote computer, right-click Start, and then choose Windows PowerShell (Admin).

Windows PowerShell Admin

Step 2. Type in the following command to configure the remote computer to receive remote commands:


Enable PS Remoting

Step 3. On the local computer, open Windows PowerShell (Admin). Enter the following command:

$servers = Get-Content 'C:\MININT\Computers.txt'

ForEach ($server in $servers)


    $MaxSize = (invoke-command -ComputerName $server -ScriptBlock { Get-PartitionSupportedSize -DriveLetter c }).sizeMax

    invoke-command -ComputerName $server -ScriptBlock {Resize-Partition -DriveLetter c -Size $using:MaxSize}


✍Note: Here the remote computer name is $servers, you need to replace $serverswith the name of your remote computer. You can also choose which drive to extend. Here we take Derive C as an example.

Resize Partition Remotely

Step 4. Then you have extended Drive C to its maximum size.

Method 2. Use the free remote desktop software

Another way for you is to use the free remote desktop software to remotely access another computer and then extend the partition on it like you’re sitting in front of it. The remote desktop software we are gonna use here is AnyViewer, which is easy, stable, and convenient as commended by thousands of users.

Part 1. Remotely access the computer using AnyViewer

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

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


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 One-click control to achieve unattended remote access.

Connect to My Devices

Note: If you want to assign more devices to achieve unattended remote access, then you can upgrade your account to a Professional or Enterprise plan. 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 the remote computer and take full control of it.

Remotely Control Another Computer

Part 2. Extend partition remotely 

Then you could start to extend the partition right on your target computer like you are sitting in front of it. You could also use PowerShell or use a professional partition assistant.

  • Option1. Use PowerShell.

Open Windows PowerShell (Admin). Type in the following commands one by one:

diskpart > list volume > select volume ### > extend size-XXX > exit

✍Note: Replace ### with the volume you want to choose and XXX with the size you want to extend.

Extend Partition PowerShell.png

  • Option 2. Use a professional partition assistant

You can use AOMEI Partition Assistant Standard, which is free, easy, yet professional freeware to help you extend partition even the unallocated space isn't contiguously behind the to-be-extended partiton. 

Step 1. Download, install, and launch AOMEI Partition Assistant. Right-click the partition you want to extend and choose Merge Partition

Merge Partitions

Step 2. Tick the unallocated space and click on OK.


Step 3. Click Apply to confirm Pending Operations and then click  Proceed to execute the operation.



This post mainly introduces two methods to extend partition remotely. The first is to use PowerShell and the second is to use the remote desktop software. You can choose one according to your own preference.