HomeBlogExplainer

Breadth-First vs Depth-First Azure Virtual Desktop Load Balancing: 3 Checks Before You Change the Setting

A white robot with a black visor routes cables from an office rack to a floating blue voxel cloud via a lit gateway

Breadth-first and depth-first are the two ways an Azure Virtual Desktop pooled host pool decides which session host a new user lands on: breadth-first spreads users across all available hosts for the best performance, and depth-first fills one host to a session limit you set before using the next, so empty hosts can be shut down. Choose breadth-first when everyone signs in at once and performance matters most; choose depth-first when users arrive gradually and you want autoscale to keep fewer machines running.

Both are settings on the same host pool, and you can change between them at any time, per Microsoft; if the pool has an autoscale scaling plan, the load balancing algorithm chosen in each phase of the plan overrides the host pool setting. The checks below and a worked day for 30 users show what each costs. Personal host pools don't use either, because each user maps to one host. Our Azure Virtual Desktop service tunes these settings for clients.

How do breadth-first and depth-first place users?

Microsoft's load balancing article describes both. Breadth-first picks a host at random from the half of available hosts with the fewest sessions, so distribution is close to even but not exact. Depth-first picks the available host with the most sessions that is still under its maximum session limit. Both send a returning user to the host that holds their existing or disconnected session, and neither sends new users to a host in drain mode.

Breadth-firstDepth-first
AimBest session performance; hosts less contendedFewest hosts running; for cost-conscious pools
Maximum session limitOptional; defaults to 999999 when the pool is created breadth-firstRequired, and it decides when the next host is used
Morning sign-in rushSpreads logons, which are CPU heavy, across hostsConcentrates logons on one host until it is full
Autoscale effectMost hosts carry a few users, so fewer can be shut downEmpty hosts are easy to shut down
Cost at list price (East US, as of December 2026)Each running D8s v5 at $0.384 an hourSame rate, fewer hours when users arrive gradually
Where to set itAzure portal, Host pools, your pool, Properties, Load balancing algorithm and Max session limit; with autoscale, the Load balancing algorithm field in each scaling plan phase (ramp-up, peak, ramp-down, off-peak) takes precedence

Check 1: Do your users arrive together or across the day?

Microsoft's sizing guidance calls user logon "a CPU-intensive operation" and says that if 30 or more users sign in within 10 minutes of each other on one 16-core host, two 8-core VMs would handle it better, adding that breadth-first spreads users across VMs where depth-first fills one first. Microsoft's autoscale article likewise recommends breadth-first for the ramp-up phase. A 9 a.m. office fits breadth-first; a firm with staggered shifts or remote staff across time zones fits depth-first.

Check 2: Have you set a realistic maximum session limit?

Depth-first needs one, and Microsoft warns that when every host reaches it you must raise the limit or add hosts. If a pool was created breadth-first, the limit sits at 999999, so switching to depth-first without changing it would pile everyone onto one host. Microsoft's terminology page adds that when many users connect at the same time, a host can end up with more sessions than the limit, so leave headroom, and the autoscale article says pools that use autoscale must have a custom maximum session limit rather than the default. Start from the sizing guidance (up to four medium users per vCPU) and adjust using AVD Insights.

Check 3: What does an empty host cost you?

Worked day: 30 users, three D8s v5 hosts

Assumptions: 30 medium users, three D8s v5 session hosts, depth-first limit of 12 sessions per host, hosts shut down only when they hold no sessions, East US Linux rate of $0.384 an hour from Microsoft's VM pricing page, as of December 2026 (AVD bills Windows 11 hosts at Linux rates).

  • A quiet Friday, 10 users for 10 hours. With all three hosts available in the morning, depth-first puts all 10 on one host and the other two can be shut down: 10 x $0.384 = $3.84. Breadth-first spreads them three or four to a host, so no host is ever empty: 30 x $0.384 = $11.52. Under autoscale the gap can be smaller, because its capacity threshold may start a second host as headroom.
  • A full Monday, 30 users at 9 a.m. Both end up running three hosts, but depth-first sends the first 12 logons to one host, where breadth-first shares the rush three ways.

Across a month of mostly full days the cash difference is small; across a month of partial attendance it adds up. Rollback: the setting changes in Properties, or in the scaling plan phase if autoscale is assigned, without rebuilding anything, and existing sessions are not affected by a lowered limit, so trial depth-first for a week and switch back if sign-in times rise.

To have a pool tuned against your real sign-in pattern, Plan my Azure project. Related: personal vs pooled host pools and Azure Virtual Desktop vs VDI.

More on this topic: Azure infrastructure guides.

Frequently asked questions

Which is the default load balancing in Azure Virtual Desktop?

You choose when you create a pooled host pool, and can change it any time. Microsoft notes that a pool created breadth-first gets a maximum session limit of 999999, which you must lower before relying on depth-first.

Does depth-first save money in Azure Virtual Desktop?

When users arrive across the day and autoscale shuts down empty hosts, yes, because fewer hosts run for fewer hours. When everyone signs in together, both methods run the same number of hosts.

Does breadth-first distribute users exactly evenly?

No. Microsoft says it picks randomly among the half of hosts with the fewest sessions, so counts can differ by a few sessions between hosts.

Sources

Azure Virtual Desktop

Discuss Azure Virtual Desktop for your business.

Tell us about your current systems, the result you need and your timeline. We will discuss the work, responsibilities and pricing before you decide on an engagement.

Explore Azure Virtual Desktop 845-203-3914