Resize a VM

Azure Portal, Hands On10 minutesFree tierSteps checked 25 October 2026By Cloud Hands On

In this task you'll change a VM's size.

If a VM is too slow, or bigger than it needs to be, you can change its size: more or fewer processors and more or less memory. The disks and settings stay the same.

Resizing restarts the VM. If the new size isn't available on the hardware the VM is running on, you have to stop (deallocate) it first, and then every size in the region is available.

Example. SS Kaiser's online shop VM struggles every December. The team resizes it to a bigger size for the sales season and back down in January, paying for the extra power only when they need it.

Before you start

You need: Virtual Machine Contributor or Contributor. Time: 10 minutes.

Where to look

  1. Virtual machines
  2. vm-practice
  3. Size

Steps

  1. Open vm-practice and select Size in the left menu.
  2. Look at the list, grouped by series: each size shows its vCPUs, memory and price, and the current size's series is marked Current.Display cost switches the price between monthly and hourly.
  3. To practise without leaving the free allowance, stop here and only look.Any size not marked as free-eligible costs money for every hour it runs.
  4. To try a resize, pick another size, such as B1ms, and select Resize. The VM restarts.Even a few minutes on a bigger size costs a few pence, so resize back straight away.
  5. Select B1s again and Resize to return to the free size.
  6. If a size is greyed out, stop (deallocate) the VM first, then try again.

Tip. Size is in the left menu under Availability + scale.

Commands

# Sizes this VM can move to without being deallocated
az vm list-vm-resize-options --resource-group rg-portal-practice --name vm-practice --output table

# Resize (the VM restarts)
az vm resize --resource-group rg-portal-practice --name vm-practice --size Standard_B1ms

# And back to the free-eligible size
az vm resize --resource-group rg-portal-practice --name vm-practice --size Standard_B1s

Watch out for

Cost
Bigger sizes cost more every hour, and leaving the free-eligible sizes means paying. Azure Advisor suggests smaller sizes for VMs that are mostly idle.
Security
Resizing doesn't change who can reach the VM, but the restart interrupts anyone using it. Warn users first.
Common mistakes
Resizing a busy server in the middle of the day. Forgetting to resize back after a test. Expecting the disk to grow too: disk size is changed separately.

Clean up

  1. Virtual machines
  2. vm-practice
  3. Size

Make sure the VM is back on B1s (or another free-eligible size). It's removed with the resource group at the end of this section.

Words to know

B-series
Low-cost sizes that build up credits when idle and use them for short bursts of work.
Right-sizing
Choosing the smallest size that does the job, to avoid paying for power you don't use.

Tick off each step and track your progress in the guide.

Open this task in Azure Portal, Hands On

Keep going