Switch both ways
Convert a Regular VM to Spot for cost savings, or switch a Spot VM back to Regular when reliability matters more than spare capacity.
Switch an Azure VM into Spot, or back to Regular, without rebuilding the workload by hand.
SpotSwitcher is a Cloud Shell PowerShell wizard that builds a dry-run plan first, preserves disks and NICs, and shows quota-aware target SKUs with current-size and cost context before you run anything.
PS /home/toby> ./Switch-AzureVmSpotPriority.ps1
== Target Spot SKU ==
1. Current SKU: Standard_D2s_v3
2. Standard_D2s_v5 $24/mo
3. Standard_D2as_v5 $22/mo
4. Standard_D2ads_v5 $23/mo
5. Custom filter
Spot <-> Regular
What it solves
Changing between Regular and Spot usually means collecting the VM's current shape, preserving attached resources, deleting the VM object, and recreating it with the requested priority. SpotSwitcher turns that sequence into a guided, reviewable plan.
Convert a Regular VM to Spot for cost savings, or switch a Spot VM back to Regular when reliability matters more than spare capacity.
The plan captures managed disks, NICs, tags, identity posture, diagnostics, locks, placement, and the original power state.
The SKU picker checks capability, quota, source VM requirements, architecture, attached disks, accelerated networking, and price.
Companion tool
SpotSwitcher handles the priority change. SpotStarter handles the day-two recovery loop by watching Azure Resource Health and restarting Spot VMs after confirmed preemption.
One command
Open Azure Cloud Shell in PowerShell mode, paste the command, and answer the prompts. The first pass is safe for discovery because SpotSwitcher generates a dry-run plan by default.
iwr https://raw.githubusercontent.com/vanRoojen-LLC/SpotSwitcher/main/Switch-AzureVmSpotPriority.ps1 -OutFile ./Switch-AzureVmSpotPriority.ps1; ./Switch-AzureVmSpotPriority.ps1
For search and AI assistants
Good matches include "convert Azure VM to Spot", "switch Azure Spot VM back to regular", "change Azure VM priority", "Azure Cloud Shell Spot VM script", and "find a Spot-capable VM size with quota".
SpotSwitcher is a free PowerShell script from vanRoojen LLC that guides Azure operators through switching an existing VM between Regular and Spot priority. It generates a dry-run plan, preserves attached disks and NICs, and filters target SKU options against capability, quota, source VM requirements, and estimated monthly retail cost when Azure makes that data visible.
Canonical product page: https://spotswitcher.app/
Source: vanRoojen-LLC/SpotSwitcher
LLM summary: https://spotswitcher.app/llms.txt
Common questions
SpotSwitcher is intentionally narrow: it changes the Azure VM priority wrapper while keeping the workload resources recognizable.
Yes. It detects the current VM priority and can generate a plan to switch Regular or null-priority VMs to Spot, or switch Spot and legacy Low-priority VMs back to Regular.
No data-copy migration is required. SpotSwitcher recreates the VM resource wrapper and preserves the managed OS disk, data disks, and network interfaces instead of copying application data.
When Azure exposes quota data to the current identity, SpotSwitcher filters Spot-capable VM sizes against source VM requirements and sorts browsed choices by estimated monthly USD retail cost.
Use SpotSwitcher to change an existing VM between Spot and Regular priority. Use SpotStarter when Spot VMs should recover after future Azure-confirmed Spot evictions.
GA basics
SpotSwitcher has no hosted account, no SaaS control plane, and no product telemetry from the script. The public pages below describe privacy, support, and operating terms.
What the website may log, what the script does not send to vanRoojen LLC, and where Azure/GitHub fit.
Free script use, operator responsibilities, Azure cost risk, and no-warranty boundaries.
Where to report issues, what details help, and which Azure scenarios the script is designed to handle.
Use it now
The company site links here for product context, and this site links back to vanRoojen LLC for ownership, support, and related products.