Odoo ERP

Odoo Access Rights Without the Mess: Groups and Record Rules

A practical guide to configuring Odoo access rights: how groups and record rules interact, the traps multi-app setups create, and how to test what a role can actually see.

Tech After Me CEOCEO & Odoo ConsultantPublished 6 min read
Share
Odoo Access Rights Without the Mess: Groups and Record Rules
On this page

Most Odoo access rights problems are not security bugs. They are the result of someone adding a group here, a record rule there, over several months, without ever stepping back to check what the combination actually produces. By the time a sales rep complains that she can see another region's quotations, nobody remembers which of the six overlapping rules is responsible.

Getting Odoo access rights right is less about memorizing every checkbox and more about understanding how two separate layers interact, then testing the result instead of assuming it. Here is how we approach it when we configure access for a new go-live or clean up an installation that grew without a plan.

Odoo access rights have two layers: the door and the room

Odoo security has two layers, and conflating them is the single most common mistake we see.

Groups (Settings > Users & Companies > Groups) decide model-level access: can this user create a vendor bill at all, can they delete a sales order, can they even see the Purchase menu. Groups also control field-level visibility in some cases, and they are inherited: a user in "Accounting / Billing" typically also belongs to a more basic "Accounting / Read-only" group underneath it.

Record rules are domain filters applied on top of a model once the group has already granted access. A record rule might say "a Sales user can only see orders where the salesperson is the current user" or "a Purchase user can only see requests for their own company." The group says yes, the record rule decides which rows.

The trap: teams often try to restrict visibility by playing only with groups, when the actual requirement is a record rule. Groups are binary per model. If you need "see your own records but not your colleague's," that is a record rule, not a stricter group.

How record rules combine, and why that surprises people

This is the detail that causes most of the confusing bugs we get asked to fix. When a user belongs to several groups, and more than one of those groups has a record rule on the same model, Odoo combines the rules with OR logic across groups, not AND.

So if a user is in "Sales / Own Documents Only" (rule: salesperson = me) and also happens to belong to another group that carries a broader rule on the sale.order model, the user ends up seeing the union of both. Removing the restrictive-looking group does not tighten access; it only removes one of several paths that already grant visibility.

Practical consequence: before you restrict a role, list every group that user (or the user's job profile) belongs to, and check which ones carry record rules on the model in question. A single missed group membership explains most "why can they still see this" tickets.

Common traps when combining apps

Odoo access rights questions rarely stay inside one app. They usually surface once Sales, Inventory, Accounting and a portal are all live together, and the same employee needs a narrow slice of each.

  • Multi-company bleed. A record rule written for Sales does not automatically apply the same logic in Accounting or Inventory. Each app ships its own default rules, and a "see own company only" fix in one module has to be checked, and sometimes replicated, in the others.
  • Portal vs internal users. Portal users (your Shopify or Lazada storefront customers, for instance) sit in a completely separate group tree from internal employees. A rule that works for an internal salesperson can expose or hide the wrong fields entirely when applied carelessly to a portal contact.
  • Approval workflows and record rules fighting each other. If a manager approval step depends on the approver being able to see the record, but a record rule restricts visibility to "own documents only," the approver gets stuck with a request they cannot open. This shows up often in purchase approval setups once limits are tightened.
  • Studio-added fields inheriting the wrong group. Fields added through Studio sometimes default to a group that is broader, or narrower, than intended, which quietly undoes a rule built around a different field. We flag this specifically when reviewing Studio customizations against the rest of the access model.
  • Inherited menus showing dead ends. A user can sometimes see a menu item because of one group, then hit "access denied" on the action behind it because a different group owns that action. This looks like a bug but is really two layers disagreeing.

A practical sequence for configuring access rights

We do not start by opening the Groups list and ticking boxes. We start by writing down roles in plain language, then translate each one into the Odoo model.

  1. List roles, not people. "Warehouse picker," "AP clerk," "regional sales manager," "finance controller." People change jobs; roles are what you actually configure.
  2. For each role, write the model-level answer first. Which apps and menus does this role touch at all? This gives you the group assignment.
  3. Then write the row-level answer. Within those models, which specific records should this role see: own records, own team, own company, own warehouse? This becomes the record rule.
  4. Check for existing rules before adding new ones. Odoo ships default record rules for most apps (multi-company rules are the most common). Extend or copy an existing rule rather than stacking a new one on top, when possible.
  5. Document the exception, not just the rule. If finance controllers should see all companies but AP clerks should only see their own, write that down next to the rule itself, in the rule's name or description field. Six months later nobody remembers the reasoning otherwise.

Testing what a role can really see

A rule that looks correct in the form view is not tested until a user with exactly that role logs in and tries to do their job. We treat this as a required step, not an optional nice-to-have, before any go-live.

The practical way to do it:

  • Create one throwaway user per role, assigned to only the groups that role should have, nothing extra inherited from being an administrator during setup.
  • Log in as that user (or use the developer-mode impersonation tool) and walk through the actual daily tasks: create a quotation, validate a delivery, post a vendor bill, approve a request.
  • Check both directions: confirm the user can do what they need, and confirm they cannot open records, reports or settings outside their scope.
  • Pay particular attention to reports and dashboards. A record rule can correctly hide a quotation in list view while an analysis report built on the same model still aggregates numbers from restricted records, because some reporting views bypass certain rule contexts.
  • Re-test after every module update. An upgrade or a new app installation can introduce new default groups and rules that interact with your custom ones in ways you did not anticipate; our upgrade planning checklist includes an access-rights re-test for exactly this reason.
LayerQuestion it answersWhere to configure
GroupCan this role open this app or model at all?Settings > Users & Companies > Groups
Record ruleWhich rows of that model can this role see or edit?Settings > Technical > Record Rules (developer mode)
Field-level securityCan this role see or edit this specific field?Group assigned directly on the field, or via Studio

The trade-off worth naming

Tighter access rights are not free. Every additional record rule is one more condition evaluated on every query against that model, and a deep chain of rules across several groups does add measurable overhead on large tables, particularly in list views and recurring reports. We have had to simplify rule logic on installations where reporting had slowed down, not because of data volume, but because of years of accumulated, overlapping rules nobody had reviewed. The fix was consolidating rules per role rather than adding one every time a new edge case appeared, not abandoning row-level security altogether.

Access rights also need ongoing ownership, not a one-time setup. As the Thai operation adds Shopee alongside Lazada, or a new regional sales team joins, the role list from step one needs a new line, and the record rules need a check against it. Teams that treat this as a configuration task done once at go-live are usually the ones who end up asking why a new hire can see last year's margins. If you are setting up or auditing access for a growing Odoo installation, our Odoo ERP development team can walk through the role list with you before the next go-live, not after the first incident.

Share

Frequently asked questions

What is the difference between a group and a record rule in Odoo?

A group controls which menus, fields and model-level actions a user can reach (create, read, write, delete on a whole model). A record rule filters which specific rows of that model the user can see or edit, written as a domain. You almost always need both: the group opens the door, the record rule decides which rooms inside it are visible.

Why can a user still see records they should not after I restricted a group?

This usually happens because another group the user belongs to carries a broader record rule, and Odoo combines multiple rules for the same model with OR logic, not AND. Check every group assigned to the user, not just the one you just edited, and consolidate overlapping rules.

Do record rules slow down Odoo?

Every active record rule adds a condition to the SQL query behind that model, so a long chain of rules across many groups does add overhead, especially on list views and reports with large tables. Keep rule logic simple and avoid rules that reference several related models when a direct field will do.

Can we test access rights without creating real user accounts for every role?

Yes, in developer mode you can use the technical menu to simulate a user's access or create one throwaway test account per role, log in as it, and click through menus. We treat this as a mandatory pre-go-live step rather than an occasional check.

Should multi-company access rules be different from department-based rules?

Yes, they solve different problems and should stay separate. Company rules restrict records to the companies a user is allowed to see; department or team rules restrict records within one company. Mixing the two logics into one rule makes the condition hard to read and hard to fix later.

Sources

About the author

Tech After Me CEO

CEO & Odoo Consultant

The CEO of Tech After Me implements, customizes and supports Odoo ERP and builds web, mobile and data products for companies in Thailand, the USA and India.

More from this author

Keep reading

Odoo API Integration: XML-RPC, JSON-RPC and Auth BasicsOdoo ERP

Odoo API Integration: XML-RPC, JSON-RPC and Auth Basics

A practical guide to Odoo API integration: how authentication, XML-RPC and JSON-RPC calls work, and the patterns that keep external systems reliably in sync.

Tech After Me CEO6 min read

Put what you read into practice

The team writing these guides is the same team that ships them. Tell us what you are working on.

Get new articles in your inbox

Get new articles in your inbox

Odoo guides and IT news that matter to your business. At most one email a week.