Blog · RevOps

How to Build Round-Robin Lead Assignment in Salesforce Without a Paid App

September 2026 · Steps reflect the Salesforce Setup and Flow Builder interface as of publication — verify in your org

Somewhere in most Salesforce orgs sits a single Lead Assignment Rule that routes every inbound lead to one queue, or worse, to whichever rep happens to be listed first. Nobody built it that way on purpose — it's what's left after "we'll set up proper routing later" got deprioritized for two years running. Fair, even distribution doesn't need a paid routing app or a consultant engagement. Salesforce ships two ways to build genuine round-robin assignment using only standard Setup tools: a formula-field method that's been the standard workaround for years, and a Flow-based method that's the more maintainable build going forward. Neither costs anything beyond the licenses you already have.

The classic method: a formula field and MOD()

The older, still-common approach needs three pieces on the Lead object. First, an Auto Number field (format {0}, starting at 0) that stamps every new lead with a sequential integer — this is your rotation counter, and it needs no code to maintain itself. Second, a formula field that runs that counter through Excel's MOD() function against the number of reps in your rotation — MOD(VALUE(Lead_Number__c), 3) for a three-rep team — which produces a repeating 0, 1, 2, 0, 1, 2 pattern as leads arrive. Third, a standard Lead Assignment Rule with one rule entry per rep, each one matching a specific formula-field value to a specific owner. The rotation is entirely mechanical: lead 1 goes to rep 0, lead 2 to rep 1, lead 3 to rep 2, lead 4 back to rep 0, with no external tool in the loop.

The tradeoff is maintenance. Adding or removing a rep means editing the MOD divisor and re-checking every rule entry by hand, and the counter has no concept of a rep being out sick — leads keep rotating to someone who isn't there to work them. It's durable and it's free, but it's also the kind of config that quietly drifts out of date the first time the sales team reorganizes.

The newer method: a Record-Triggered Flow

The more current build replaces the formula field with logic that can actually reason about your team, and it's the direction Salesforce's own admin guidance now points teams toward. Start with a custom field on the User object — a Date/Time field like Last Lead Assigned — that records when each rep most recently received a lead. Then build a Record-Triggered Flow on Lead creation that queries your rotation group of Users, sorts by that field ascending, and assigns the new lead to whoever has waited longest since their last one — then updates that rep's timestamp so they move to the back of the line. Salesforce's standard Assign Leads flow action can reference that Last-Assigned field directly as its rotation input, so the whole build stays inside declarative Flow Builder with no Apex.

This version handles the case the formula method can't: pull a rep out of the querying group (a checkbox field like Available for Rotation works well) and the Flow simply stops assigning to them until you flip it back, no divisor math required. Growing the team means adding a User to the rotation group, not editing a formula.

Don't forget leads that skip the automation

Both methods above fire on lead creation through whatever's actually creating the lead — a web-to-lead form, an API integration, a data import. They don't fire when a rep or admin creates a lead by hand in the Salesforce UI, because a manually entered lead already has an owner: whoever created it. To route those into the same rotation, add a checkbox to the Lead page layout — something like Trigger Round-Robin Assignment — and have your assignment rule or Flow entry criteria check for it. Anyone hand-entering a lead ticks the box before saving, and it drops into the same queue as everything else instead of quietly sitting with whoever happened to type it in.

Where this approach stops being enough

Neither build accounts for deal size, rep capacity, or territory — they distribute strictly by count, which is the right call for inbound leads of roughly similar value and the wrong call the moment you need to weight assignment by, say, company size or product line (our guide to lead tracking for multiple product lines in Salesforce covers that adjacent problem). And if your org is on Salesforce Starter or another Essentials-tier edition, check Setup first — a built-in Round Robin Lead Assignment Rule type ships there natively, which makes either DIY method above unnecessary. For everyone else, the Flow-based build is worth the extra hour over the formula-field version: it's the one that survives your next org chart change without someone remembering to go back and edit a MOD divisor. Getting the rotation itself right is only half the fix, too — a fairly distributed lead is still a cold one if the campaign data that explains why it converted didn't survive the trip, which is the gap our guide to capturing UTM parameters in Salesforce web-to-lead forms closes.

Routing is one gate in a much longer pipeline from first touch to closed-won. The audit maps the whole thing and finds where leads actually stall.

Book an audit

← All posts