---
schema_version: "1"
id: 1e48101ea78515d58c6aac6985231f21aa12e657e8d86e7cd2cbcdc052832c09
title: Automatically Grant or Revoke Access with a User Access Policy
collection: admin
version: current
locale: en-us
portal_url: https://docs.salesforce.com/admin/current/en-us/platform/264-0-0/perm_active_user_access_policy.md
canonical_url: https://help.salesforce.com/s/articleView?id=platform.perm_active_user_access_policy.htm&release=264.0.0&type=5
source_site: help.salesforce.com
content_type: documentation
content_hash: d9ccbf6a36ee1e117f8d1cfe9d4c6f57ecde7f54598e09e2188ddf267992a432
description: Grant or revoke access for a specified set of users through a triggered event, such as a created or updated user record.
products:
  - Security
  - Salesforce Platform
release: "264"
---
# Automatically Grant or Revoke Access with a User Access Policy

Grant or revoke access for a specified set of users through a triggered event, such as a created or updated user record.

### Required Editions

<table class="slds-table slds-table_bordered slds-max-medium-table_stacked slds-m-bottom_small edition"><colgroup><col></colgroup><tbody><tr class=""><td class="slds-cell-wrap" style="vertical-align:top;">Available in: both Salesforce Classic (not available in all orgs) and Lightning Experience</td></tr><tr class=""><td class="slds-cell-wrap" style="vertical-align:top;">Available in: <strong>Enterprise</strong> and <strong>Unlimited</strong> editions</td></tr></tbody></table>

<table class="slds-table slds-table_bordered slds-max-medium-table_stacked slds-m-bottom_small permission">
        <colgroup>
          <col style="width:50%">
          <col style="width:50%">
        </colgroup>
        <thead class="slds-text-title_caps ">
          <tr class="">
            <th scope="colgroup" class="slds-cell-wrap" colspan="2" style="text-align:center;vertical-align:top;" id="d39763e66">User Permissions Needed</th>
          </tr>
        </thead>
        <tbody>
          <tr class="">
            <td data-label="User Permissions Needed" class="slds-cell-wrap" style="vertical-align:top;" headers="d39763e66 ">To modify user access policies:</td>

            <td class="slds-cell-wrap" style="vertical-align:top;" headers="d39763e66 ">Manage User Access Policies</td>

          </tr>
        </tbody>
      </table>

These instructions describe how to create user access policies that automatically run whenever qualified user records are created or updated. If you want to create user access policies that you run manually, such as for a user access migration or a one-time user access update, see [Manually Grant or Revoke Access with a User Access Policy](https://help.salesforce.com/s/articleView?id=platform.perm_manual_user_access_policies.htm&release=264.0.0&type=5 "Migrate or change users’ assignments to access mechanisms with a one-time, manual application of a user access policy.").

1. From Setup, in the Quick Find box, enter User Management Settings, and then select **User Management Settings**. Make sure that both the User Access Policies and Enhanced Interface for User Access Policies settings are enabled.
    
    If Salesforce enabled user access policies for you before the Summer ’23 release, you must enable this feature again on the User Management Settings page.
2. In the Quick Find box, enter User Access Policies, and then select **User Access Policies**.
3. Click **New User Access Policy**.
4. Enter a value for the Policy Name and Description. The API Name auto-populates.
5. Add a value for the Order field. If a user meets the criteria for multiple active policies, the policy with the lowest order value is applied.
6. Click **Save**.
7. On the user access policy’s detail page, click **Edit Criteria** to configure the policy’s user criteria filters and actions.
8. Under Define User Criteria, add at least one user criteria filter. Use the `Equals` operator for a single value and the `In` operator for multiple values. Policies are applied to users that meet all of the criteria filters. You can have:
    1. Up to 3 filters for applicable users
    2. Up to 10 filters on standard and custom user fields of type Checkbox, Number, Picklist, or Text
    3. Multiple roles or profiles referenced in the same filter using the `In` operator
9. Under Define Actions, select **Grant** or **Revoke** from the Action picklist, then select the access mechanism that the action applies to. Access options are:
    
    1. Permission sets
    2. Permission set groups
    3. Permission set licenses
    4. Package licenses
    5. Public groups
    6. Queues
    
    User access policies support up to 20 actions.
10. Save your changes.
11. Click **Automate Policy**, then select when to trigger the policy:
    - The user access policy runs only when a user who matches the policy criteria is created.
    - The user access policy runs only when a user is updated to match the policy criteria.
    - The user access policy runs when a user who matches the policy criteria is either created or updated.
12. Click **Activate**.
    
    After you automate the policy, the status changes to Active.

On the policy’s detail page under the Recent User Access Changes tab, you can monitor when this policy is applied and the affected users.

#### See Also

- [User Access Policies](https://help.salesforce.com/s/articleView?id=platform.perm_user_access_policies.htm&release=264.0.0&type=5 "With user access policies, you define aggregated access for your users in a single operation. Automate your users’ assignments to permission set licenses, permission sets, permission set groups, package licenses, queues, and public groups. You can create policies that grant or remove access whenever users are created or updated, or in a one-time manual migration.")
- [Manually Grant or Revoke Access with a User Access Policy](https://help.salesforce.com/s/articleView?id=platform.perm_manual_user_access_policies.htm&release=264.0.0&type=5 "Migrate or change users’ assignments to access mechanisms with a one-time, manual application of a user access policy.")
- [User Access Policy Considerations](https://help.salesforce.com/s/articleView?id=platform.perm_user_access_policy_considerations.htm&release=264.0.0&type=5 "Be aware of these considerations and special behaviors for user access policies.")