Currently in my org having Territory rules as follows,

"Account: Account OwnerEQUALS User1"

then Account will assign with "Abc" territory.

When we change the Account Owner in Classic View, then the territory rules are working fine. However, when we try to do the same in Lightning Experience view, the territory rules are not triggering.

How can we achieve this in Lightning Experience view as well using Invokable method?


2 Answers 2


The back-end system does not automatically run territory assignment rules when an account is changed. Furthermore Flows/Apex do not have a direct way to run territory rules.

With Classic, there is an "Evaluate this account against territory rules on save" checkbox on the account page layout. This is enabled on the Layout Properties button when editing the layout. If you edit an account in Classic and this field is checked, the territory rules will run.

HOWEVER, this checkbox is not available in Lightning and does not work even though the page layout is used on the record page.

The only way you can run territory rules on account update is to write Flow/Apex to make a REST API callout back into Salesforce. A REST API PATCH on the account will run the territory rules.


Maybe I'm missing something here with the previous answers, but I believe you can turn on this functionality in Lightning.

Go to Setup->Object Manager->Account->[Account Layout or whichever page Layout you want]. Click on Layout Properties and select the checkbox Show On Edit Page for "Evaluate this account against territory rules on save."

You can also select the Default checkbox if you want Territory Assignment Rules to be run every time a record is updated (without having to select the checkbox each time on the edit screen).

  • You can make this setting but the territory rules still do not fire in Lightning UI. Oct 2, 2023 at 22:57
  • If you’re talking about editing on the Detail page, I agree the TM rules won’t fire. But, if you edit on the Edit screen with ‘Evaluate this account against territory rules on save,’ then the TM rules definitely fire and take effect. The kicker for the OP question is that you can’t modify the Account Owner from the Edit screen, so it’s true that he’d need to use Flow/Apex for this case. Perhaps that’s what you were saying all along, but I read your post as saying that territory rules will not fire on any account update, and that is not the case. Try it out if you disagree.
    – zargosh
    Oct 3, 2023 at 6:08

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .