# Source: https://docs.unifygtm.com/reference/integrations/salesforce/lead-assignment-rules.md

> ## Documentation Index
> Fetch the complete documentation index at: https://docs.unifygtm.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Toggle Lead Assignment Rules in Salesforce

> Troubleshoot a common bug in Salesforce related to lead assignment rules.

## Explanation

Salesforce allows you to create "lead assignment rules" that automatically assign different owners to leads depending on custom criteria. However, sometimes these rules don’t work right off the bat due to a specific bug in Salesforce. The steps outlined here should resolve the issue.

## Steps

### Ensure you have an active lead assignment rule

Navigate to the **Setup** page in Salesforce by clicking the settings icon in the top-right corner of any Salesforce page.

<Frame><img src="https://mintcdn.com/unify-19/hCdysogYM6qFbUs-/images/active-lead-assignment-rule-step-1.png?fit=max&auto=format&n=hCdysogYM6qFbUs-&q=85&s=225c290fe4ff35d75b032c2708a8fa19" alt="active-lead-assignment-rule-step-1" data-og-width="362" width="362" data-og-height="402" height="402" data-path="images/active-lead-assignment-rule-step-1.png" data-optimize="true" data-opv="3" srcset="https://mintcdn.com/unify-19/hCdysogYM6qFbUs-/images/active-lead-assignment-rule-step-1.png?w=280&fit=max&auto=format&n=hCdysogYM6qFbUs-&q=85&s=184d7b7e426ae232f68970899cb6293f 280w, https://mintcdn.com/unify-19/hCdysogYM6qFbUs-/images/active-lead-assignment-rule-step-1.png?w=560&fit=max&auto=format&n=hCdysogYM6qFbUs-&q=85&s=00f4179c5b6623b1b7f03d9301319f29 560w, https://mintcdn.com/unify-19/hCdysogYM6qFbUs-/images/active-lead-assignment-rule-step-1.png?w=840&fit=max&auto=format&n=hCdysogYM6qFbUs-&q=85&s=aa30939addb0d1ab9e1b7cadaffebc78 840w, https://mintcdn.com/unify-19/hCdysogYM6qFbUs-/images/active-lead-assignment-rule-step-1.png?w=1100&fit=max&auto=format&n=hCdysogYM6qFbUs-&q=85&s=cc09fc24f119cded80f0f78a349a0b4e 1100w, https://mintcdn.com/unify-19/hCdysogYM6qFbUs-/images/active-lead-assignment-rule-step-1.png?w=1650&fit=max&auto=format&n=hCdysogYM6qFbUs-&q=85&s=0a00de7f6b4f79570690a94b026ca3f6 1650w, https://mintcdn.com/unify-19/hCdysogYM6qFbUs-/images/active-lead-assignment-rule-step-1.png?w=2500&fit=max&auto=format&n=hCdysogYM6qFbUs-&q=85&s=6976bbed56c8fbcd0c245b7b345ee51e 2500w" /></Frame>

Search for **Lead Assignment Rules** in the sidebar.

<Frame><img src="https://mintcdn.com/unify-19/hCdysogYM6qFbUs-/images/active-lead-assignment-rule-step-2.png?fit=max&auto=format&n=hCdysogYM6qFbUs-&q=85&s=df1192fdef7dbe47181e75614280823c" alt="active-lead-assignment-rule-step-2" data-og-width="500" width="500" data-og-height="500" height="500" data-path="images/active-lead-assignment-rule-step-2.png" data-optimize="true" data-opv="3" srcset="https://mintcdn.com/unify-19/hCdysogYM6qFbUs-/images/active-lead-assignment-rule-step-2.png?w=280&fit=max&auto=format&n=hCdysogYM6qFbUs-&q=85&s=213b145a065c299739a8812ddbd4b91f 280w, https://mintcdn.com/unify-19/hCdysogYM6qFbUs-/images/active-lead-assignment-rule-step-2.png?w=560&fit=max&auto=format&n=hCdysogYM6qFbUs-&q=85&s=4f2c2fe19c92729a99e0728d8037f3d2 560w, https://mintcdn.com/unify-19/hCdysogYM6qFbUs-/images/active-lead-assignment-rule-step-2.png?w=840&fit=max&auto=format&n=hCdysogYM6qFbUs-&q=85&s=19835957d052f59bb1d4117600dc695a 840w, https://mintcdn.com/unify-19/hCdysogYM6qFbUs-/images/active-lead-assignment-rule-step-2.png?w=1100&fit=max&auto=format&n=hCdysogYM6qFbUs-&q=85&s=6c042ee9a0fe71f63c274c1b06439c27 1100w, https://mintcdn.com/unify-19/hCdysogYM6qFbUs-/images/active-lead-assignment-rule-step-2.png?w=1650&fit=max&auto=format&n=hCdysogYM6qFbUs-&q=85&s=14dcc758fb424281569b2d93d867e05d 1650w, https://mintcdn.com/unify-19/hCdysogYM6qFbUs-/images/active-lead-assignment-rule-step-2.png?w=2500&fit=max&auto=format&n=hCdysogYM6qFbUs-&q=85&s=16cd30e960bccfedffe7f0363de20f0f 2500w" /> </Frame>

You should see at least one rule with a checkmark under the **Active** column.

<Frame><img src="https://mintcdn.com/unify-19/hCdysogYM6qFbUs-/images/active-lead-assignment-rule-step-3.png?fit=max&auto=format&n=hCdysogYM6qFbUs-&q=85&s=c4ecd26c8b2c77122f1b5650d37b8046" alt="active-lead-assignment-rule-step-3" data-og-width="2388" width="2388" data-og-height="620" height="620" data-path="images/active-lead-assignment-rule-step-3.png" data-optimize="true" data-opv="3" srcset="https://mintcdn.com/unify-19/hCdysogYM6qFbUs-/images/active-lead-assignment-rule-step-3.png?w=280&fit=max&auto=format&n=hCdysogYM6qFbUs-&q=85&s=95b6ed3868e31e096d8a15dbadb0114f 280w, https://mintcdn.com/unify-19/hCdysogYM6qFbUs-/images/active-lead-assignment-rule-step-3.png?w=560&fit=max&auto=format&n=hCdysogYM6qFbUs-&q=85&s=c5fddcc136790d2e4b6330134f8bac14 560w, https://mintcdn.com/unify-19/hCdysogYM6qFbUs-/images/active-lead-assignment-rule-step-3.png?w=840&fit=max&auto=format&n=hCdysogYM6qFbUs-&q=85&s=52708fbb18f1d514ad56e7e7bda132ec 840w, https://mintcdn.com/unify-19/hCdysogYM6qFbUs-/images/active-lead-assignment-rule-step-3.png?w=1100&fit=max&auto=format&n=hCdysogYM6qFbUs-&q=85&s=95a79c352cf107be1d2220c4ee0ab929 1100w, https://mintcdn.com/unify-19/hCdysogYM6qFbUs-/images/active-lead-assignment-rule-step-3.png?w=1650&fit=max&auto=format&n=hCdysogYM6qFbUs-&q=85&s=2ec062fb468dfadd769e0a76c26a6d38 1650w, https://mintcdn.com/unify-19/hCdysogYM6qFbUs-/images/active-lead-assignment-rule-step-3.png?w=2500&fit=max&auto=format&n=hCdysogYM6qFbUs-&q=85&s=03de90833a114a45e74d86c1d3b836f8 2500w" /> </Frame>

### Toggle the rule off and on

In the **Lead Assignment Rules** page from the previous step, click on the name of your rule and then select **Edit**. Uncheck the checkbox next to **Active** to temporarily deactivate the rule.

<Frame><img src="https://mintcdn.com/unify-19/QTxNj2fcd-br9FnE/images/toggle-rule-off-on-step-2.png?fit=max&auto=format&n=QTxNj2fcd-br9FnE&q=85&s=2ffa4ba0241fb40208789e10f54051c6" alt="toggle-rule-off-on-step-2" data-og-width="1012" width="1012" data-og-height="558" height="558" data-path="images/toggle-rule-off-on-step-2.png" data-optimize="true" data-opv="3" srcset="https://mintcdn.com/unify-19/QTxNj2fcd-br9FnE/images/toggle-rule-off-on-step-2.png?w=280&fit=max&auto=format&n=QTxNj2fcd-br9FnE&q=85&s=67c7c8085ed9a51af38eb62dd497cdae 280w, https://mintcdn.com/unify-19/QTxNj2fcd-br9FnE/images/toggle-rule-off-on-step-2.png?w=560&fit=max&auto=format&n=QTxNj2fcd-br9FnE&q=85&s=4df5e094e2bdd229fa679ed58c592c68 560w, https://mintcdn.com/unify-19/QTxNj2fcd-br9FnE/images/toggle-rule-off-on-step-2.png?w=840&fit=max&auto=format&n=QTxNj2fcd-br9FnE&q=85&s=c14403847c82acd1687dd60f9cdaa74e 840w, https://mintcdn.com/unify-19/QTxNj2fcd-br9FnE/images/toggle-rule-off-on-step-2.png?w=1100&fit=max&auto=format&n=QTxNj2fcd-br9FnE&q=85&s=9d89930bcfee5233786579fc922c1ba6 1100w, https://mintcdn.com/unify-19/QTxNj2fcd-br9FnE/images/toggle-rule-off-on-step-2.png?w=1650&fit=max&auto=format&n=QTxNj2fcd-br9FnE&q=85&s=6a270381b55d2145f6013e4c3993728a 1650w, https://mintcdn.com/unify-19/QTxNj2fcd-br9FnE/images/toggle-rule-off-on-step-2.png?w=2500&fit=max&auto=format&n=QTxNj2fcd-br9FnE&q=85&s=8e82479a0a60eaa87b845cbfe1df8e79 2500w" /> </Frame>

Click **Save**. Then click **Edit** again, re-check the checkbox next to **Active**, and then choose **Save**.

### Test that leads are assigned correctly in the UI

Navigate to the **Leads** page in Salesforce. You can get there via the app launcher.

<Frame><img src="https://mintcdn.com/unify-19/QTxNj2fcd-br9FnE/images/test-leads-correctly-assigned-step-1.png?fit=max&auto=format&n=QTxNj2fcd-br9FnE&q=85&s=44d52b741ccb9a6009cabc35e9bef711" alt="test-leads-correctly-assigned-step-1" data-og-width="648" width="648" data-og-height="482" height="482" data-path="images/test-leads-correctly-assigned-step-1.png" data-optimize="true" data-opv="3" srcset="https://mintcdn.com/unify-19/QTxNj2fcd-br9FnE/images/test-leads-correctly-assigned-step-1.png?w=280&fit=max&auto=format&n=QTxNj2fcd-br9FnE&q=85&s=97c769dc6529eb6a9a59968482b69a70 280w, https://mintcdn.com/unify-19/QTxNj2fcd-br9FnE/images/test-leads-correctly-assigned-step-1.png?w=560&fit=max&auto=format&n=QTxNj2fcd-br9FnE&q=85&s=ec33620fa1c94207eda0b654b131b106 560w, https://mintcdn.com/unify-19/QTxNj2fcd-br9FnE/images/test-leads-correctly-assigned-step-1.png?w=840&fit=max&auto=format&n=QTxNj2fcd-br9FnE&q=85&s=e20812e634d4b61bf3522cb61191ca7d 840w, https://mintcdn.com/unify-19/QTxNj2fcd-br9FnE/images/test-leads-correctly-assigned-step-1.png?w=1100&fit=max&auto=format&n=QTxNj2fcd-br9FnE&q=85&s=ee5ed898d955c6923c161c93ff591fd2 1100w, https://mintcdn.com/unify-19/QTxNj2fcd-br9FnE/images/test-leads-correctly-assigned-step-1.png?w=1650&fit=max&auto=format&n=QTxNj2fcd-br9FnE&q=85&s=54b0e936c8a82b4f49f8ccb5978045b9 1650w, https://mintcdn.com/unify-19/QTxNj2fcd-br9FnE/images/test-leads-correctly-assigned-step-1.png?w=2500&fit=max&auto=format&n=QTxNj2fcd-br9FnE&q=85&s=67f6b605cc525a40e2bec780677a2441 2500w" /> </Frame>

In the top-right corner of the screen, select **New** to create a new lead.

<Frame><img src="https://mintcdn.com/unify-19/QTxNj2fcd-br9FnE/images/test-leads-correctly-assigned-step-2.png?fit=max&auto=format&n=QTxNj2fcd-br9FnE&q=85&s=a82b6a990a7ce6fed11bae2b771725a5" alt="test-leads-correctly-assigned-step-2" data-og-width="1126" width="1126" data-og-height="82" height="82" data-path="images/test-leads-correctly-assigned-step-2.png" data-optimize="true" data-opv="3" srcset="https://mintcdn.com/unify-19/QTxNj2fcd-br9FnE/images/test-leads-correctly-assigned-step-2.png?w=280&fit=max&auto=format&n=QTxNj2fcd-br9FnE&q=85&s=52df0afc42719245fd61c9ea2cf40322 280w, https://mintcdn.com/unify-19/QTxNj2fcd-br9FnE/images/test-leads-correctly-assigned-step-2.png?w=560&fit=max&auto=format&n=QTxNj2fcd-br9FnE&q=85&s=7da4c8e8e7ec8cfe4c0f2649b12fe533 560w, https://mintcdn.com/unify-19/QTxNj2fcd-br9FnE/images/test-leads-correctly-assigned-step-2.png?w=840&fit=max&auto=format&n=QTxNj2fcd-br9FnE&q=85&s=21d4bdc2b8e4a393b524900936683138 840w, https://mintcdn.com/unify-19/QTxNj2fcd-br9FnE/images/test-leads-correctly-assigned-step-2.png?w=1100&fit=max&auto=format&n=QTxNj2fcd-br9FnE&q=85&s=26a8c9a2eae8de3818d25dd9b8aa1fb5 1100w, https://mintcdn.com/unify-19/QTxNj2fcd-br9FnE/images/test-leads-correctly-assigned-step-2.png?w=1650&fit=max&auto=format&n=QTxNj2fcd-br9FnE&q=85&s=1e9e8afad0002fc4b79758ee41bc6da6 1650w, https://mintcdn.com/unify-19/QTxNj2fcd-br9FnE/images/test-leads-correctly-assigned-step-2.png?w=2500&fit=max&auto=format&n=QTxNj2fcd-br9FnE&q=85&s=f564a8560f90962ced5a19ec5e4eae64 2500w" /> </Frame>

Check the **Assign using active assignment rule** checkbox in the lower-left corner.

<Frame><img src="https://mintcdn.com/unify-19/QTxNj2fcd-br9FnE/images/test-leads-correctly-assigned-step-3.png?fit=max&auto=format&n=QTxNj2fcd-br9FnE&q=85&s=ca073da311624856c0b44932b7f81538" alt="test-leads-correctly-assigned-step-3" data-og-width="1994" width="1994" data-og-height="1206" height="1206" data-path="images/test-leads-correctly-assigned-step-3.png" data-optimize="true" data-opv="3" srcset="https://mintcdn.com/unify-19/QTxNj2fcd-br9FnE/images/test-leads-correctly-assigned-step-3.png?w=280&fit=max&auto=format&n=QTxNj2fcd-br9FnE&q=85&s=ffffd30dcf0394ffd53dca7d208ad7b0 280w, https://mintcdn.com/unify-19/QTxNj2fcd-br9FnE/images/test-leads-correctly-assigned-step-3.png?w=560&fit=max&auto=format&n=QTxNj2fcd-br9FnE&q=85&s=c11bdc9e77b28a5e944068c94f31e989 560w, https://mintcdn.com/unify-19/QTxNj2fcd-br9FnE/images/test-leads-correctly-assigned-step-3.png?w=840&fit=max&auto=format&n=QTxNj2fcd-br9FnE&q=85&s=31ace94fe3f4cace937bb2b85570b480 840w, https://mintcdn.com/unify-19/QTxNj2fcd-br9FnE/images/test-leads-correctly-assigned-step-3.png?w=1100&fit=max&auto=format&n=QTxNj2fcd-br9FnE&q=85&s=217b4bce8079654faefbc02dc070070c 1100w, https://mintcdn.com/unify-19/QTxNj2fcd-br9FnE/images/test-leads-correctly-assigned-step-3.png?w=1650&fit=max&auto=format&n=QTxNj2fcd-br9FnE&q=85&s=ee85d339a6346d1fad7d0511c841a88c 1650w, https://mintcdn.com/unify-19/QTxNj2fcd-br9FnE/images/test-leads-correctly-assigned-step-3.png?w=2500&fit=max&auto=format&n=QTxNj2fcd-br9FnE&q=85&s=9c4dd7318441e762f4b869964ddd6299 2500w" /> </Frame>

Fill out the required lead fields with values that should trigger the lead assignment rule you created and then click **Save** in the bottom-right corner.

Lastly, verify that the lead was assigned to the correct owner.