How to Check Record Access Using UserRecordAccess in Flow
UserRecordAccess is a system-calculated Salesforce object that simplifies checking record-level access for any user without complex sharing logic. By querying this object with both UserId and RecordId, Salesforce professionals can determine edit, read, delete, and transfer permissions in real-time. This unlocks powerful declarative automation possibilities, such as building secure Flow-based screens that show UI elements dynamically based on access, or creating admin utilities to audit user access across records efficiently. Understanding its limitations and query requirements is key to building robust, error-free solutions.
- Query UserRecordAccess with both UserId and RecordId filters to check record permissions.
- Select RecordId explicitly in Flow Get Records to avoid runtime errors.
- Use Flow decision elements to show/hide UI based on UserRecordAccess permissions.
- Run Flow DML updates in system context to bypass ownership transfer restrictions.
- Leverage UserRecordAccess to build admin access auditing utilities with autolaunched Flows.
Determining who actually has access to a record in an enterprise Salesforce org can be surprisingly complex. Record visibility can be affected by Organization-Wide Defaults, role hierarchies, sharing rules, Enterprise Territory Management, account, opportunity, and case teams, manual shares, profiles, permission sets, and more. Trying to calculate record access manually by querying individual Share objects can quickly turn into complicated logic that is difficult to build, test, and maintain. Fortunately, Salesforce provides a much easier way to check record access: the UserRecordAccess object. In this post, we will explain how UserRecordAccess works, review its capabilities and limitations, show how to query it with SOQL, and build practical examples that use it in Salesforce Flow. What is UserRecordAccess? UserRecordAccess is a read-only, system-calculated virtual object.